1
0

Fix indentations and add reload_nginx function in library

This commit is contained in:
JrCs 2016-01-05 14:02:15 +01:00
parent 1c6d70b93f
commit a263aad670
2 changed files with 13 additions and 11 deletions

@ -21,3 +21,10 @@ remove_all_location_configurations() {
sed -i "/$START_HEADER/,/$END_HEADER/d" "$file"
done
}
reload_nginx() {
if [[ -n "$NGINX_PROXY_CID" ]]; then
/usr/bin/docker exec -t $NGINX_PROXY_CID \
sh -c '/usr/local/bin/docker-gen -only-exposed /app/nginx.tmpl /etc/nginx/conf.d/default.conf;nginx -s reload'
fi
}

@ -7,11 +7,6 @@ acme_ca_uri="${ACME_CA_URI:-https://acme-v01.api.letsencrypt.org/directory}"
source /app/functions.lib
reload_nginx() {
/usr/bin/docker exec -t $NGINX_PROXY_CID \
sh -c '/usr/local/bin/docker-gen -only-exposed /app/nginx.tmpl /etc/nginx/conf.d/default.conf;nginx -s reload'
}
update_certs() {
[[ ! -f "$DIR"/letsencrypt_service_data ]] && return