14 lines
426 B
Bash
Executable File
14 lines
426 B
Bash
Executable File
#!/bin/sh
|
|
set -e
|
|
|
|
HTTPS_CONF="/etc/nginx/conf.d/https.conf"
|
|
HTTPS_TEMPLATE="/etc/nginx/nginx-https.conf"
|
|
|
|
if [ -f /etc/nginx/ssl/fullchain.pem ] && [ -f /etc/nginx/ssl/privkey.pem ]; then
|
|
cp "$HTTPS_TEMPLATE" "$HTTPS_CONF"
|
|
echo "[gc-frontend] HTTPS enabled — listening on 443"
|
|
else
|
|
rm -f "$HTTPS_CONF" 2>/dev/null || true
|
|
echo "[gc-frontend] HTTPS skipped — place fullchain.pem + privkey.pem in /etc/nginx/ssl"
|
|
fi
|