Don't overwrite external index.html
This commit is contained in:
parent
6023686304
commit
4a6b75d8f3
1 changed files with 4 additions and 2 deletions
|
@ -61,14 +61,16 @@ EOF
|
||||||
# create empty file - can be overriden by others
|
# create empty file - can be overriden by others
|
||||||
touch /etc/nginx/https.conf
|
touch /etc/nginx/https.conf
|
||||||
|
|
||||||
cat > "${wwwroot}/index.html" <<EOF
|
# Do not overwrite if external volume is used!
|
||||||
|
if [ ! -e ${wwwroot}/index.html ]; then
|
||||||
|
cat > "${wwwroot}/index.html" <<EOF
|
||||||
Welcome to ${dnsname} running with IPv6+LetsEncrypt.
|
Welcome to ${dnsname} running with IPv6+LetsEncrypt.
|
||||||
|
|
||||||
Find more about fully automated docker containers with letsencrypt certificates on
|
Find more about fully automated docker containers with letsencrypt certificates on
|
||||||
|
|
||||||
https://ungleich.ch/u/blog/fully-automated-ssl-certificates-for-docker/
|
https://ungleich.ch/u/blog/fully-automated-ssl-certificates-for-docker/
|
||||||
EOF
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
# restart and run now with cert
|
# restart and run now with cert
|
||||||
pkill nginx
|
pkill nginx
|
||||||
|
|
Loading…
Reference in a new issue