diff options
author | elijah <elijah@riseup.net> | 2013-08-01 12:31:57 -0700 |
---|---|---|
committer | elijah <elijah@riseup.net> | 2013-08-01 12:31:57 -0700 |
commit | 7d6893194cf1b6b8f4b3afa407d70dc90fe25f6c (patch) | |
tree | 50937e53491663bf28cfb53811849cf8b972f776 /puppet/modules | |
parent | da191971398827f81ddb0dffd86d4a3c572f6386 (diff) |
run soledad daemon using the configured port.
Diffstat (limited to 'puppet/modules')
-rw-r--r-- | puppet/modules/soledad/manifests/server.pp | 11 | ||||
-rw-r--r-- | puppet/modules/soledad/templates/default-soledad.erb | 4 |
2 files changed, 13 insertions, 2 deletions
diff --git a/puppet/modules/soledad/manifests/server.pp b/puppet/modules/soledad/manifests/server.pp index 00fee4ac..ba482f29 100644 --- a/puppet/modules/soledad/manifests/server.pp +++ b/puppet/modules/soledad/manifests/server.pp @@ -13,6 +13,9 @@ class soledad::server { $x509_cert = $x509['cert'] $x509_ca = $x509['ca_cert'] + $soledad = hiera('soledad') + $soledad_port = $soledad['port'] + x509::key { 'soledad': content => $x509_key, notify => Service['soledad-server']; @@ -46,8 +49,12 @@ class soledad::server { } file { '/etc/default/soledad': - content => "CERT_PATH=/etc/x509/certs/soledad.crt\nPRIVKEY_PATH=/etc/x509/keys/soledad.key\n", - require => Package['soledad-server'] + content => template('soledad/default-soledad.erb'), + owner => 'soledad', + group => 'soledad', + mode => '0600', + notify => Service['soledad-server'], + require => Class['soledad']; } service { 'soledad-server': diff --git a/puppet/modules/soledad/templates/default-soledad.erb b/puppet/modules/soledad/templates/default-soledad.erb new file mode 100644 index 00000000..da85338a --- /dev/null +++ b/puppet/modules/soledad/templates/default-soledad.erb @@ -0,0 +1,4 @@ +# this file is managed by puppet +CERT_PATH=/etc/x509/certs/soledad.crt +PRIVKEY_PATH=/etc/x509/keys/soledad.key +HTTPS_PORT=<%=@soledad_port%> |