updated nginx role
This commit is contained in:
parent
1a925c6491
commit
ec46090afb
1 changed files with 0 additions and 38 deletions
|
@ -1,38 +0,0 @@
|
|||
server {
|
||||
listen 443 ssl proxy_protocol;
|
||||
server_name {{ item.domain }} ;
|
||||
|
||||
resolver 172.16.40.20;
|
||||
set $backend "http://localhost:{{ item.port }}";
|
||||
set $certbot "http://localhost";
|
||||
|
||||
ssl_certificate /etc/nginx/certs/{{ item.domain }}.actcur.com/fullchain.pem;
|
||||
ssl_certificate_key /etc/nginx/certs/{{ item.domain }}.actcur.com/privkey.pem;
|
||||
|
||||
location /.well-known/acme-challenge/ {
|
||||
proxy_pass $certbot;
|
||||
proxy_set_header Host $host;
|
||||
}
|
||||
|
||||
ssl_session_cache shared:SSL:10m;
|
||||
client_max_body_size 1024m;
|
||||
location / {
|
||||
allow 192.168.0.0/16;
|
||||
deny all;
|
||||
|
||||
proxy_pass $backend;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Forwarded-Proto https;
|
||||
proxy_set_header X-Forwarded-Port 443;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
proxy_set_header X-Forwarded-Ssl on;
|
||||
|
||||
# re-write redirects to http as to https, example: /home
|
||||
proxy_redirect http:// https://;
|
||||
}
|
||||
|
||||
error_log /var/log/nginx/{{ domain }}_error.log;
|
||||
access_log /var/log/nginx/{{ domain }}_access.log;
|
||||
}
|
||||
|
Loading…
Add table
Reference in a new issue