Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: modules/trac/manifests/init.pp

Issue 5731052198821888: #1203 - Establish nginx::hostconfig-fragment() directive (Closed)
Patch Set: #1203 - Migrate Trac setup to nginx::hostconfig-fragment Created Aug. 13, 2014, 9:24 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « modules/nginx/templates/site.erb ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: modules/trac/manifests/init.pp
===================================================================
--- a/modules/trac/manifests/init.pp
+++ b/modules/trac/manifests/init.pp
@@ -2,7 +2,6 @@
$domain,
$certificate,
$private_key,
- $fcgi_config_dir = '/etc/nginx/trac.d',
$is_default = false) inherits private::trac {
package {['python-mysqldb','python-pip','subversion', 'tofrodos', 'graphviz']:
@@ -11,20 +10,11 @@
include nginx, spawn-fcgi
- file {$fcgi_config_dir:
- ensure => directory,
- owner => 'root',
- mode => 755,
- require => Package['nginx'],
- }
-
nginx::hostconfig {$domain:
- content => "include $fcgi_config_dir/*;",
is_default => $is_default,
certificate => $certificate,
private_key => $private_key,
log => 'access_log_trac',
- require => File[$fcgi_config_dir],
}
user {'trac':
@@ -151,13 +141,9 @@
$location_base = regsubst($location, '/+$', '')
- file {"${trac::fcgi_config_dir}/${name}.conf":
- ensure => file,
- owner => 'root',
- mode => 644,
+ nginx::hostconfig-fragment {"nginx_fragment_$name":
content => template('trac/fcgi.conf.erb'),
- require => File[$trac::fcgi_config_dir],
- notify => Service['nginx'],
+ domain => $trac::domain,
}
exec {"trac_env_${name}":
« no previous file with comments | « modules/nginx/templates/site.erb ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld