Certs were not being saved by LetsEncrypt for Nginx correctly. Should be working now.
This commit is contained in:
@@ -18,12 +18,14 @@ echo "CERT_DIR=$CERT_DIR"
|
||||
mkdir -pv $CERT_DIR
|
||||
|
||||
# Loop over the proxy configuration files and ensure they have certs.
|
||||
grep -l proxy_pass $DIR/config/conf.d/*.* | while read file; do
|
||||
#grep -l proxy_pass $DIR/config/conf.d/*.* | while read file; do
|
||||
ls $DIR/config/conf.d/*.* | while read file; do
|
||||
filename=`basename $file`
|
||||
echo "*** Checking $filename ***"
|
||||
echo -e "\n\n*** Checking $filename ***"
|
||||
if [[ ! -d $CERT_DIR/$filename ]]; then
|
||||
echo "Creating self-signed certs at $CERT_DIR/$filename."
|
||||
mkdir -pv $CERT_DIR/$filename
|
||||
touch $CERT_DIR/$filename/SELF
|
||||
openssl req -new -x509 -days 3 -nodes \
|
||||
-out $CERT_DIR/$filename/fullchain.pem \
|
||||
-keyout $CERT_DIR/$filename/privkey.pem \
|
||||
|
Reference in New Issue
Block a user