Re: Re: Environment variable availability within post-install script
Re: Re: Environment variable availability within post-install script
- Subject: Re: Re: Environment variable availability within post-install script
- From: Tim Streater <email@hidden>
- Date: 10 May 2010 19:14 +0100
On 10 May 2010 at 18:22, Greg Neagle <email@hidden> wrote:
> Again, I urge installer writers to consider other scenarios that make this
> sort of thing problematic.
Greg,
I take the points you're making and appreciate the issues you've raised. However, in my own situation, I should perhaps point out that this is an entirely new area for me. Until about a couple of weeks ago I'd not even heard of PackageMaker (although obviously I knew some sort of program like that must exist). I was just bumbling along thinking that when development of my app reached a certain point, I'd check out how I could install it. Well that certain point has arrived, so I'm diving into what for me are entirely new waters.
> Consider a company or school where the primary users do not have
> administrative rights:
>
> 1) An admin physically visits each machine, logs in with his/her admin
> account, and runs the installer. Your user-specific stuff is installed in the
> home for the admin account. The admin logs out and the primary user logs back
> in. How do they get your user-specific stuff?
Seems to me that if Smith is installing it as admin on behalf of Jones, then Smith has to signal this to the installer. Now, how does this usually work? I've only ever installed stuff for myself (or for "all users"). I'm not sure I've come across an installer that asks who you're installing the s/w for. At my present level of ignorance, I don't know how to put up a panel asking the person staring at the screen whether they're installing for (a) all users (b) a specific user - enter shortname, or (c) themself. And more particularly, how to save that information and make it available to a script later in the install process.
> 2) The organization has remote deployment software that installs your software
> while no-one is logged in, or in the root context using /usr/sbin/installer.
> Assuming your scripts don't barf in this scenario, when a user later logs in,
> how do they get your user specific stuff?
>
> 3) The primary user leaves the company and a new user takes over the position
> and the machine, getting a new user account in the process. How do they get
> your user-specific stuff?
>
> There may be multiple users for a given machine - even in a home environment.
> How does a user other than the one that manually ran your installer get the
> user-specific stuff?
>
> Don't think you can just search for additional user folders under /Users and
> molest those as you install -- that won't cover new users added after the
> install; current users not-logged in whose home directories are protected with
> FileVault, or network users.
>
> If there are resources that must be copied to each user's home directory,
> consider using a LaunchAgent installed in /Library/LaunchAgents that checks
> for these resources and copies them from a cache at login.
These are all scenarios I've not considered yet - first I'll be glad to get working a simple setup where the user logs in as themself and double-clicks the .pkg.
> Or modify the application to do this upon launch.
What I'm giving them is a .webloc file, which is what they'd need to launch the app.
> This way you cover all possible user account scenarios. This pushes the
> responsibility from the installer-writer to the software developer, which is
> where it belongs.
Well, I agree with this (to the extent possible).
Thanks for your detailed list.
Tim Streater
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden