aboutsummaryrefslogtreecommitdiff
path: root/scripts/hostclass/public_webserver
diff options
context:
space:
mode:
authorCullum Smith <cullum@sacredheartsc.com>2024-10-31 21:36:39 -0400
committerCullum Smith <cullum@sacredheartsc.com>2024-10-31 21:36:39 -0400
commit2c9845db4bc00221bc3c2343a020208f7f532166 (patch)
tree843bc24a1bbf2cad33c4bdc8a17c3d0d838fceb4 /scripts/hostclass/public_webserver
parent7eb111136453d0e8d8451d7dd85ba9892318f294 (diff)
downloadinfrastructure-2c9845db4bc00221bc3c2343a020208f7f532166.tar.gz
many fixes
Diffstat (limited to 'scripts/hostclass/public_webserver')
-rw-r--r--scripts/hostclass/public_webserver6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/hostclass/public_webserver b/scripts/hostclass/public_webserver
index 3877313..e92149f 100644
--- a/scripts/hostclass/public_webserver
+++ b/scripts/hostclass/public_webserver
@@ -20,8 +20,8 @@ zfs set \
"${state_dataset}/vhosts"
# Configure nginx.
-install_template -m 0644 /usr/local/etc/nginx/nginx.conf
-install -Cv -m 0644 /dev/null /usr/local/etc/nginx/vhosts.conf
+install_template -m 0644 "${nginx_conf_dir}/nginx.conf"
+[ -f "${nginx_conf_dir}/vhosts.conf" ] || install -Cv -m 0644 /dev/null "${nginx_conf_dir}/vhosts.conf"
sysrc -v nginx_enable=YES
service nginx restart
@@ -37,7 +37,7 @@ for certname in $acme_certs; do
done
# Now that we have the ACME certs, add the vhosts.
-install_template -m 0644 /usr/local/etc/nginx/vhosts.conf
+install_template -m 0644 "${nginx_conf_dir}/vhosts.conf"
service nginx restart
# If any acmeproxy_domains were specified, setup the SFTP proxy.