Commit 8da41999 by source_reader

added directories to pi install

parent fa6fe91b
Showing with 26 additions and 3 deletions
class nginx::pi{ class nginx::pi{
notice("including pi nginx") notice("including pi nginx")
$dirs = ['/usr/lib/nginx','/usr/lib/nginx/modules',
'/usr/share/nginx', '/usr/share/nginx/html']
file {$dirs:,
owner => root,
group => root,
ensure => directory
}
file {'/etc/nginx/nginx.conf': file {'/etc/nginx/nginx.conf':
source => 'puppet:///modules/nginx/nginx.conf', source => 'puppet:///modules/nginx/nginx.conf',
owner => root, owner => root,
group => root, group => root,
mode => '0644', mode => '0644',
require => File['/etc/nginx']
} }
file {'/etc/nginx/site.conf': file {'/etc/nginx/site.conf':
source => 'puppet:///modules/nginx/site.conf', source => 'puppet:///modules/nginx/site.conf',
owner => root, owner => root,
group => root, group => root,
mode => '0644', mode => '0644',
require => File['/etc/nginx']
} }
file {'/etc/nginx': file {'/etc/nginx':
ensure => directory, ensure => directory,
...@@ -21,11 +29,18 @@ class nginx::pi{ ...@@ -21,11 +29,18 @@ class nginx::pi{
recurse => true, recurse => true,
source => 'puppet:///modules/nginx/pi/conf' source => 'puppet:///modules/nginx/pi/conf'
} }
file{'/etc/nginx/conf.d':
ensure => directory,
owner => root,
group => root,
require => File['/etc/nginx']
}
file {'/etc/nginx/conf.d/passenger.conf': file {'/etc/nginx/conf.d/passenger.conf':
ensure => directory, ensure => directory,
owner => root, owner => root,
group => root, group => root,
source => 'puppet:///modules/nginx/pi/passenger.conf' source => 'puppet:///modules/nginx/pi/passenger.conf'
require => File['/etc/nginx/conf.d']
} }
file {'/usr/lib/nginx/modules': file {'/usr/lib/nginx/modules':
...@@ -33,7 +48,8 @@ class nginx::pi{ ...@@ -33,7 +48,8 @@ class nginx::pi{
owner => root, owner => root,
group => root, group => root,
recurse => true, recurse => true,
source => 'puppet:///modules/nginx/pi/objs' source => 'puppet:///modules/nginx/pi/objs',
require => File['/usr/lib/nginx']
} }
file{'/usr/share/nginx/html': file{'/usr/share/nginx/html':
owner => root, owner => root,
...@@ -41,6 +57,7 @@ class nginx::pi{ ...@@ -41,6 +57,7 @@ class nginx::pi{
ensure => directory, ensure => directory,
recurse => true, recurse => true,
source => 'puppet:///modules/nginx/pi/html', source => 'puppet:///modules/nginx/pi/html',
require => File['/usr/share/nginx']
} }
file{'/usr/sbin/nginx': file{'/usr/sbin/nginx':
owner => root, owner => root,
...@@ -53,9 +70,15 @@ class nginx::pi{ ...@@ -53,9 +70,15 @@ class nginx::pi{
group => root, group => root,
source => 'puppet:///modules/nginx/pi/nginx.service' source => 'puppet:///modules/nginx/pi/nginx.service'
} }
package {'passenger':
ensure => "6.0.4",
provider => gem,
}
service {'nginx': service {'nginx':
ensure => running, ensure => running,
require => [File['/etc/systemd/system/nginx.conf']] require => [File['/etc/systemd/system/nginx.service'],
Package['passenger']]
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment