docker-nginx-auto/app/add-proxy.sh

20 lines
301 B
Bash
Raw Normal View History

2021-08-20 11:28:41 -04:00
#!/bin/sh
NAME="$1"
URL="$2"
. /root/common.sh
cat > "${CONF}/conf.d/auto.${NAME}.conf" <<EOF
server {
server_name ${NAME};
server_tokens off;
include snippets/ssl.conf;
include snippets/gzip.conf;
location / {
proxy_pass ${URL};
include snippets/reverse-proxy.conf;
}
}
EOF