Skip to main content
Question

Issue with application running on log in


Forum|alt.badge.img+6

Hello everybody, I'm running into an issue every now and then, and I'm not sure how to fix it or how it breaks.

I've wrote a script to map network drives according to AD group memberships and saved it as an application. I then created a configuration payload for Login Items and pointed it to the app.

When logging in, the app pops up in the dock for a short second, and then quits. Manually trying to launch the app does the same thing. Opening the package contents and trying to run the script does nothing either.

Is there a way to check why this is happening, or is there a better way to have network volumes mounted based off of AD memberships and groups?

3 replies

Forum|alt.badge.img+17
  • Valued Contributor
  • 231 replies
  • December 8, 2016

Try starting the script application from the command line in terminal without using open or other handlers and see what it reports, if anything, as it attempts to run.

/path/to/your/Script_App.app/Contents/MacOS/applet

Forum|alt.badge.img+6
  • Author
  • Contributor
  • 24 replies
  • December 9, 2016

@joshuasee Tried what you said, and it does the same thing as if I went and just clicked on it from my Applications folder. It pops open briefly in the dock and closes right away.

Manually going into the package contents and running the applet I got the following.

Last login: Fri Dec 9 08:38:29 on ttys000
/Applications/LoginScript.app/Contents/MacOS/applet ; exit;
TH_TECH_MBP01:~ fbaker$ /Applications/LoginScript.app/Contents/MacOS/applet ; exit;
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.
Deleting expired sessions...none found.

[Process completed]


bentoms
Forum|alt.badge.img+35
  • Legendary Contributor
  • 4331 replies
  • December 10, 2016

@fbaker Sounds like an issue with the AppleScript...

I'm guessing this might have been based on something I blogged a few years ago? I might be able to help, but we'd need to see the AppleScript...

Are you on the macadmins.org slack? If not, join up.. there's an AppleScript channel there. Mention me (macmule), & if about I can have a look.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings