Update and rename 30-keygen to 30-certs_keygen

This commit is contained in:
Alexandre
2021-09-21 20:24:33 +02:00
committed by GitHub
parent 7b58c855be
commit f0e705bd14
2 changed files with 28 additions and 10 deletions

View File

@@ -1,10 +0,0 @@
#!/usr/bin/with-contenv bash
/defaults/nextcloud-perms.sh
SUBJECT="/C=US/ST=CA/L=Carlsbad/O=Linuxserver.io/OU=LSIO Server/CN=*"
if [[ -f /ssl/nextcloud/keys/cert.key && -f /ssl/nextcloud/keys/cert.crt ]]; then
echo "using keys found in /ssl/nextcloud/keys"
else
echo "generating self-signed keys in /ssl/nextcloud/keys, you can replace these with your own keys if required"
openssl req -new -x509 -days 3650 -nodes -out /ssl/nextcloud/keys/cert.crt -keyout /ssl/nextcloud/keys/cert.key -subj "$SUBJECT"
fi