Hi there

In my playbook I have:

    - name: Setup someuser user
      user: name=someuser shell=/bin/bash

Now I observe this from within the VM:

someuser@precise32:~/techdocs$ ls -lhd /home/someuser/
drwxr-xr-x 3 root root 4.0K May 14 07:15 /home/someuser/

How do I end up with a root-owned home directory?

I suspect this is what happened: I have this in my `Vagrantfile`:

  config.vm.synced_folder "./techdocs", "/home/someuser/techdocs", create: 
true, owner: "someuser", group: "someuser" 

This executed before the provisioning had completed, and raised an error 
that `someuser` did not exist.
After provisioning completed, it does not fail, but I'm stuck with a 
root-owned homedir. 
Is there a way to avoid this? Ansible is supposed to facilitate repeatable 
deploys, but in this case one would have to deploy with a `Vagrantfile` 
without synced_folder, and then re-deploy with a `Vagrantfile` including 
the synced folder. That's rather awkward.

Regards, 
Jean

-- 
You received this message because you are subscribed to the Google Groups 
"Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to