Skip to content

Instantly share code, notes, and snippets.

@johnrobertwilson
Created June 22, 2012 17:14
Show Gist options
  • Save johnrobertwilson/2974044 to your computer and use it in GitHub Desktop.
Save johnrobertwilson/2974044 to your computer and use it in GitHub Desktop.
vhost.pp
class robinhood::vhost {
File {
owner => "apache",
group => "apache",
mode => "0755",
require => Class["apache"],
}
file { "/var/www" :
ensure => directory,
}
file { "/var/www/vhosts" :
ensure => directory,
require => File["/var/www"],
}
file { "/var/www/vhosts/RobinHood.org" :
ensure => directory,
require => File["/var/www/vhosts"],
}
file { "/var/www/vhosts/RobinHood.org/htdocs" :
ensure => directory,
require => File["/var/www/vhosts/RobinHood.org"],
}
file { "/var/www/vhosts/RobinHood.org/data" :
ensure => directory,
require => File["/var/www/vhosts/RobinHood.org"],
}
file { "/var/www/vhosts/RobinHood.org/basic-auth" :
ensure => present,
content => "robinhood:oEpEHprThY/pY",
require => File["/var/www/vhosts/RobinHood.org"],
}
file { "/var/www/vhosts/RobinHood.org/htdocs/sites" :
ensure => directory,
require => File["/var/www/vhosts/RobinHood.org/htdocs"],
}
file { "/var/www/vhosts/RobinHood.org/htdocs/sites/default" :
ensure => directory,
require => File["/var/www/vhosts/RobinHood.org/htdocs/sites"],
}
file { "/var/www/vhosts/robinhood-toolkit" :
ensure => directory,
require => File["/var/www/vhosts"],
}
file { "/var/www/vhosts/robinhood-toolkit/htdocs" :
ensure => directory,
require => File["/var/www/vhosts/robinhood-toolkit"],
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment