I am a Vagrant and Puppet newbie, I have created a Base Box with Debian Squeeze plus standalone Puppet, using the instructions here to install Puppet with the Puppetlabs packages.
The box itself seems to import successfully but once I get onto provisioning it, I get errors that seem to be to do with the nfs share on the host. 1000 is the uid of the Vagrant user on the vm.
Error:
Error: Failed to set owner to '1000': Operation not permitted - /vagrant/www/index.php
Error: /Stage[main]/Perchdemo::Sites::Create/File[/vagrant/www/index.php]/owner: change from 501 to vagrant failed: Failed to set owner to '1000': Operation not permitted - /vagrant/www/index.php
This occurs when I copy the index.php file into the share /vagrant/www on the host filesystem using Puppet. I have used this Puppet module on a standalone install of Puppet on a vm where the files were hosted on the filesystem of the vm, ideally though I'd like them to be on the nfs share.
Edited with a bit more information. Having had a poke around the error initially occurs when I create the vhost using the puppetlabs apache module. However whichever user I try and force that to create under, it fails with the same error.
My VagrantFile for this is as follows.
Vagrant::Config.run do |config|
config.vm.box = "squeeze64"
config.vm.network :hostonly, "10.1.0.52"
config.nfs.map_uid = :auto
config.nfs.map_gid = :auto
config.vm.forward_port 80, 8080
config.vm.share_folder("v-web", "/vagrant/www", "./www", :nfs => true)
config.vm.provision :shell, :inline => "echo \"Europe/London\" | sudo tee /etc/timezone && dpkg-reconfigure --frontend noninteractive tzdata"
config.vm.provision :shell, :inline => "apt-get update --fix-missing"
config.vm.provision :shell, :inline => "apt-get upgrade"
config.vm.provision :puppet do |puppet|
puppet.facter = { "fqdn" => "perchtutorial.eoms"}
puppet.manifests_path = "puppet/manifests"
puppet.manifest_file = "perchtutorial.pp"
puppet.module_path = "puppet/modules"
end
end