-
Notifications
You must be signed in to change notification settings - Fork 249
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
User home directory not populated until Finder is launched #69
Comments
Looks like this might be expected. Digging around in the |
Yes. On an OS X / macOS system a newly-created user will have its home directory auto-created if it's created via the Users & Groups pref pane, but otherwise it's only created upon its first login to the system. This repo's user creation script (part of pkg-postinstall) does pre-create one or two locations as they're needed as part of the provisioning, but otherwise the user dir as a whole isn't set up. I've actually implemented what was suggested in the above solution in another project that borrows some ideas from this osx-vm-templates repo.. wherein I just copy the English User Template into the new user's directory at the time of the package script. It's been in use for a few months and hasn't caused any issues. I would be fine with also copying out the User Template to create the user's home dir, except as is indicated in MagerValp/CreateUserPkg#47, there's a question of which locale to copy in. I think realistically, however, defaulting to English.lproj may be fine for the applications of this repo. |
Thanks for responding - I've been poking at this in my [limited] spare time this week and I'm having trouble implementing the change you mentioned. I'm attempting to include the contents of mkdir -p "$SUPPORT_DIR/pkgroot/Users/$USER"
/bin/cp -Rp "$SUPPORT_DIR/English.lproj/." "$SUPPORT_DIR/pkgroot/$USER/" And I feel like I'm really missing something basic! |
Oh, well it would help if I got my paths right. Can you tell its been a long week? Let's try that with: mkdir -p "$SUPPORT_DIR/pkgroot/Users/$USER"
/bin/cp -Rp "$SUPPORT_DIR/English.lproj/" "$SUPPORT_DIR/pkgroot/Users/$USER" |
What you want to do is do this during the postinstall script, something like: /bin/cp -Rp "$3/System/Library/User Template/English.lproj" "$3/Users/$USER" The |
Oh of course! You're recommending I pull the |
Yes, the idea is you've now just installed the OS, and you're now running whatever tasks can only easily be done from a machine in the same install environment, with a newly-installed OS attached as a non-booted volume. |
Well, your suggestion worked great for populating the home folder -- I am still finding that the icon for the Documents folder in Finder is blank until I:
Which seems weird, but I don't suspect will actually cause any real issues for me. |
Huh, so, weirdly, there is no Weird weird weird! It's pretty trivial to make one at the same time I'm copying over |
Oh, that might be in Non_localized. There's another command called |
You are correct, it's in |
I am having a super weird issue.
Building the packer box with the 10.11.5 Installer and all the default
packer build
settings, folders like theDocuments
folder are NOT in myvagrant
user's home directory:Opening a Finder window will generate the directories, but until I reboot the VM the
Documents
shortcut icon in Finder is blankI started having this issue with modified version of this build that I've been using internally (all credit given in the documentation), and honestly this has probably been going on for months and I've just ignored it.
I decided to just pull down your build clean and see if the issue persisted and it seems to. The weird thing is that I've build this project a few times, trying different things like skipping updates, and it has generated the home folders a couple of times - but I can't figure out what setting seems to help it along.
It's totally possible that this is expected, but I'm honestly still pretty new to OSX administration. This project has been crucial in helping me learn how to effectively manage OSX clients, I really appreciate you sharing it with us!
Here is all the relevant information I can think of:
Building with the OS 10.11.5 Installer via the latest commit of this project into packer .10.1 and vagrant 1.8.4 into VMWare Fusion Pro 8.1.1 with the vagrant-vmware-fusion plugin (4.0.10)
The text was updated successfully, but these errors were encountered: