puppet: Abstract out ssl certs and private keys dirs.

This commit is contained in:
rht 2019-01-05 14:18:46 +00:00 committed by Tim Abbott
parent 91348a6aee
commit bf65f86a0b
2 changed files with 6 additions and 2 deletions

View File

@ -6,6 +6,10 @@ class zulip::app_frontend {
$nginx_http_only = zulipconf('application_server', 'http_only', undef)
$no_serve_uploads = zulipconf('application_server', 'no_serve_uploads', undef)
$ssl_dir = $::osfamily ? {
'debian' => '/etc/ssl',
'redhat' => '/etc/pki/tls',
}
file { '/etc/nginx/sites-available/zulip-enterprise':
ensure => file,
require => Package[$zulip::common::nginx],

View File

@ -15,8 +15,8 @@ server {
listen 443;
ssl on;
ssl_certificate /etc/ssl/certs/zulip.combined-chain.crt;
ssl_certificate_key /etc/ssl/private/zulip.key;
ssl_certificate <%= @ssl_dir %>/certs/zulip.combined-chain.crt;
ssl_certificate_key <%= @ssl_dir %>/private/zulip.key;
<% end -%>
<% if @no_serve_uploads == '' -%>