Cleanup puppet modules
Make files notify services to restart when changed Improve planet's cron, spit out a date/time and append instead of overwrite log Change-Id: I0c2ee96c4aff5512a891c49b8b2df5c20c9cab44
This commit is contained in:
parent
a56778c211
commit
265fdefba1
|
@ -20,7 +20,7 @@ class planet {
|
|||
ensure => directory
|
||||
}
|
||||
|
||||
service { 'nginx':
|
||||
service { "nginx":
|
||||
ensure => running,
|
||||
hasrestart => true
|
||||
}
|
||||
|
|
|
@ -4,7 +4,8 @@ define planet::site($git_url) {
|
|||
ensure => present,
|
||||
content => template("planet/nginx.erb"),
|
||||
replace => true,
|
||||
require => Package[nginx]
|
||||
require => Package[nginx],
|
||||
notify => Service[nginx]
|
||||
}
|
||||
|
||||
file { "/etc/nginx/sites-enabled/planet-${name}":
|
||||
|
@ -33,7 +34,7 @@ define planet::site($git_url) {
|
|||
cron { "update_planet_${name}":
|
||||
user => root,
|
||||
minute => "*/5",
|
||||
command => "cd /var/lib/planet/${name} && planet /var/lib/planet/${name}/planet.ini > /var/log/planet/${name}.log 2>&1"
|
||||
command => "date >> /var/log/planet/${name}.log && cd /var/lib/planet/${name} && planet /var/lib/planet/${name}/planet.ini >> /var/log/planet/${name}.log 2>&1"
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue