mirror of
https://github.com/Mailu/Mailu.git
synced 2025-02-15 13:33:21 +02:00
Fix the nginx startup script
(cherry picked from commit e26c6f7a6e462fd7e907494b8e68b213315cc43d)
This commit is contained in:
parent
1454ef9c9a
commit
22e7ee9dbe
@ -1,11 +1,10 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
if [[ -z ENABLE_CERTBOT || -f /certs/cert.pem ]]
|
if [ -z ENABLE_CERTBOT ] || [ -f /certs/cert.pem ]
|
||||||
then
|
then
|
||||||
cp /etc/nginx/nginx.conf.default /etc/nginx/nginx.conf
|
cp /etc/nginx/nginx.conf.default /etc/nginx/nginx.conf
|
||||||
else
|
else
|
||||||
openssl req -newkey rsa:2048 -x509 -keyout /tmp/snakeoil.pem -out /tmp/snakeoil.pem -days 365 -nodes -subj "/C=NA/ST=None/
|
openssl req -newkey rsa:2048 -x509 -keyout /tmp/snakeoil.pem -out /tmp/snakeoil.pem -days 365 -nodes -subj "/C=NA/ST=None/L=None/O=None/CN=$DOMAIN"
|
||||||
L=None/O=None/CN=$DOMAIN"
|
|
||||||
cp /etc/nginx/nginx.conf.fallback /etc/nginx/nginx.conf
|
cp /etc/nginx/nginx.conf.fallback /etc/nginx/nginx.conf
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user