diff options
author | Micah <micah@leap.se> | 2016-05-24 10:19:27 -0400 |
---|---|---|
committer | Micah <micah@leap.se> | 2016-05-24 10:19:27 -0400 |
commit | af6fdd31fb961fc1b7f408f51001e7a6d192a58a (patch) | |
tree | 8e5e443c2958f07027ebb60595007dd5b755d3a0 /manifests/ssl/deploy_cert.pp |
Squashed 'puppet/modules/couchdb/' content from commit 76ff149
git-subtree-dir: puppet/modules/couchdb
git-subtree-split: 76ff149a095023611c05bbb00157d06f87b07c05
Diffstat (limited to 'manifests/ssl/deploy_cert.pp')
-rw-r--r-- | manifests/ssl/deploy_cert.pp | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/manifests/ssl/deploy_cert.pp b/manifests/ssl/deploy_cert.pp new file mode 100644 index 00000000..d3e743f1 --- /dev/null +++ b/manifests/ssl/deploy_cert.pp @@ -0,0 +1,28 @@ +define couchdb::ssl::deploy_cert ($cert, $key) { + + include couchdb::params + + file { 'couchdb_cert_directory': + ensure => 'directory', + path => $couchdb::params::cert_path, + mode => '0600', + owner => 'couchdb', + group => 'couchdb'; + } + + file { 'couchdb_cert': + path => "${couchdb::params::cert_path}/server_cert.pem", + mode => '0644', + owner => 'couchdb', + group => 'couchdb', + content => $cert + } + + file { 'couchdb_key': + path => "${couchdb::params::cert_path}/server_key.pem", + mode => '0600', + owner => 'couchdb', + group => 'couchdb', + content => $key + } +} |