|
|
@ -15,9 +15,15 @@ if [ ! -e /config/mime.types ]; then |
|
|
|
cp /etc/nginx/mime.types /config/mime.types; |
|
|
|
cp /etc/nginx/mime.types /config/mime.types; |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Check if conf.d directory exists |
|
|
|
|
|
|
|
if [ ! -d /config/conf.d ]; then |
|
|
|
|
|
|
|
echo "Directory /config/conf.d not found. Creating it..."; |
|
|
|
|
|
|
|
mkdir /config/conf.d |
|
|
|
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
# Check if conf.d directory has websites configuration files |
|
|
|
# Check if conf.d directory has websites configuration files |
|
|
|
if [ -z "$(ls -A /config/conf.d)" ]; then |
|
|
|
if [ -z "$(ls -A /config/conf.d)" ]; then |
|
|
|
echo "The /config/conf.d directory is empty. Copying default.conf..."; |
|
|
|
echo "Directory /config/conf.d directory empty. Copying default.conf..."; |
|
|
|
cp /etc/nginx/conf.d/default.conf /config/conf.d/default.conf; |
|
|
|
cp /etc/nginx/conf.d/default.conf /config/conf.d/default.conf; |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|