Running an apple script as the logged in user through Self service

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 03-11-2010 09:50 AM
I want to publish some scripts for changing Entourage settings in Self
Service. I have found though they do not work properly because they are
being run as root rather than the logged in user. I have not pushed
something before and had it run as the user... I think I should use the $3
variable... but not sure if it should be in my script, or in the policy for
Self Service.
Any help is appreciated... thank you,
Ken

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 03-11-2010 12:21 AM
Only policies triggered by Login or Logout hooks will utilize the current user information in $3 I’m thinking.
Aside from that you would need to actually get the currently logged on user another way if you’re trying to manipulate information in that Users home directory.
ls -l /dev/console | awk '{ print $3}
Hopefully I’m not misunderstanding what you are trying to do.
Craig E
