initial public commit
This commit is contained in:
commit
6456bc19ce
17 changed files with 1613 additions and 0 deletions
97
nginx_templates/conf.d/default.conf.template
Normal file
97
nginx_templates/conf.d/default.conf.template
Normal file
|
@ -0,0 +1,97 @@
|
|||
server {
|
||||
listen 80;
|
||||
|
||||
return 301 https://${DOLLAR}host${DOLLAR}request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
include /etc/nginx/ssl_listen.conf;
|
||||
|
||||
location / {
|
||||
error_page 404 /404.html;
|
||||
root /var/www/html;
|
||||
index index.html index.htm;
|
||||
}
|
||||
|
||||
location /.well-known/acme-challenge {
|
||||
root /var/www;
|
||||
}
|
||||
|
||||
location ~ /\.(?!well-known).* {
|
||||
return 404;
|
||||
access_log off;
|
||||
log_not_found off;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
include /etc/nginx/ssl_listen.conf;
|
||||
|
||||
server_name git.${BASE_DOMAIN_NAME};
|
||||
|
||||
location /.well-known/acme-challenge {
|
||||
root /var/www;
|
||||
}
|
||||
|
||||
location / {
|
||||
proxy_pass http://forgejo:3000;
|
||||
|
||||
proxy_set_header Connection ${DOLLAR}http_connection;
|
||||
proxy_set_header Upgrade ${DOLLAR}http_upgrade;
|
||||
proxy_set_header Host ${DOLLAR}host;
|
||||
proxy_set_header X-Real-IP ${DOLLAR}remote_addr;
|
||||
proxy_set_header X-Forwarded-For ${DOLLAR}proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto ${DOLLAR}scheme;
|
||||
|
||||
client_max_body_size 512M;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
include /etc/nginx/ssl_listen.conf;
|
||||
|
||||
location /.well-known/acme-challenge {
|
||||
root /var/www;
|
||||
}
|
||||
|
||||
server_name mail.${BASE_DOMAIN_NAME};
|
||||
location / {
|
||||
proxy_pass http://mail:80;
|
||||
|
||||
proxy_set_header Connection ${DOLLAR}http_connection;
|
||||
proxy_set_header Upgrade ${DOLLAR}http_upgrade;
|
||||
proxy_set_header Host ${DOLLAR}host;
|
||||
proxy_set_header X-Real-IP ${DOLLAR}remote_addr;
|
||||
proxy_set_header X-Forwarded-For ${DOLLAR}proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto ${DOLLAR}scheme;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
include /etc/nginx/ssl_listen.conf;
|
||||
|
||||
location /.well-known/acme-challenge {
|
||||
root /var/www;
|
||||
}
|
||||
|
||||
server_name forum.${BASE_DOMAIN_NAME};
|
||||
location / {
|
||||
proxy_pass http://unix:/forum/nginx.http.sock:;
|
||||
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Connection ${DOLLAR}http_connection;
|
||||
proxy_set_header Upgrade ${DOLLAR}http_upgrade;
|
||||
proxy_set_header Host ${DOLLAR}host;
|
||||
proxy_set_header X-Real-IP ${DOLLAR}remote_addr;
|
||||
proxy_set_header X-Forwarded-For ${DOLLAR}proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto ${DOLLAR}scheme;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
include /etc/nginx/ssl_listen.conf;
|
||||
|
||||
server_name ~^(?<subdomain>.*)${ALT_BASE_DOMAIN_NAME}${DOLLAR};
|
||||
return 301 https://${DOLLAR}{subdomain}${BASE_DOMAIN_NAME}${DOLLAR}request_uri;
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue