address PR request comments for minor cleanup
This commit is contained in:
parent
67821fcc0d
commit
d49c7c544f
|
@ -16,7 +16,7 @@ Create a config directory for your custom configs:
|
||||||
mkdir conf.d
|
mkdir conf.d
|
||||||
```
|
```
|
||||||
|
|
||||||
And a `.conf` file such as in that directory:
|
And a `.conf` in that directory:
|
||||||
```nginx
|
```nginx
|
||||||
server {
|
server {
|
||||||
listen 443 ssl;
|
listen 443 ssl;
|
||||||
|
@ -43,7 +43,7 @@ services:
|
||||||
environment:
|
environment:
|
||||||
- CERTBOT_EMAIL=owner@company.com
|
- CERTBOT_EMAIL=owner@company.com
|
||||||
volumes:
|
volumes:
|
||||||
- ./conf.d:/etc/nginx/user.conf.d
|
- ./conf.d:/etc/nginx/user.conf.d :ro
|
||||||
...
|
...
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
|
@ -10,4 +10,5 @@ services:
|
||||||
- "80:80"
|
- "80:80"
|
||||||
- "443:443"
|
- "443:443"
|
||||||
volumes:
|
volumes:
|
||||||
- ./conf.d:/etc/nginx/user.conf.d
|
- ./conf.d:/etc/nginx/user.conf.d :ro
|
||||||
|
|
||||||
|
|
|
@ -96,8 +96,8 @@ is_renewal_required() {
|
||||||
# to /etc/nginx/conf.d so they are included as configs
|
# to /etc/nginx/conf.d so they are included as configs
|
||||||
# this allows a user to easily mount their own configs
|
# this allows a user to easily mount their own configs
|
||||||
link_user_configs() {
|
link_user_configs() {
|
||||||
SOURCE_DIR=${1-/etc/nginx/user.conf.d}
|
SOURCE_DIR="${1-/etc/nginx/user.conf.d}"
|
||||||
TARGET_DIR=${2-/etc/nginx/conf.d}
|
TARGET_DIR="${2-/etc/nginx/conf.d}"
|
||||||
|
|
||||||
echo "symlinking scripts from ${SOURCE_DIR} to ${TARGET_DIR}"
|
echo "symlinking scripts from ${SOURCE_DIR} to ${TARGET_DIR}"
|
||||||
|
|
||||||
|
@ -105,8 +105,7 @@ link_user_configs() {
|
||||||
echo "no ${SOURCE_DIR}, nothing to do."
|
echo "no ${SOURCE_DIR}, nothing to do."
|
||||||
else
|
else
|
||||||
for conf in ${SOURCE_DIR}/*.conf; do
|
for conf in ${SOURCE_DIR}/*.conf; do
|
||||||
echo "symlinking: ${conf}" "${TARGET_DIR}/$(basename ${conf})"
|
ln -sv "${conf}" "${TARGET_DIR}/$(basename ${conf})"
|
||||||
ln -s "${conf}" "${TARGET_DIR}/$(basename ${conf})"
|
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
}
|
}
|
Loading…
Reference in New Issue