How to: Create a directory with Puppet

How to create a directory with puppet

If you are creating a website you need to make sure that the directories are in the remote system before you can push the files in to them this is how you do it.

# make sure that the folder /var/www/myfolder/ 
# is in the new system, including permissions
file { "/var/www/myfolder/":
ensure => "directory",
owner => "www-data",
group => "www-data",
mode => 644,
}

 

I am a Senior System Administrator that work daily with Virtualization,Xenserver, Linux, IT automation, Ansible,Windows, Active Directory, Exchange and a lot more. Here you will find tips and trix from early junior, middle junior and senior to unique information of the topics I mentioned earlier. If you need help with something do not hesitate to contact me I will gladly help.

Tagged with: ,