rename files with conf type,

cleanup other config files

Signed-off-by: Arthur Lu <learthurgo@gmail.com>
This commit is contained in:
Arthur Lu 2023-03-31 21:32:29 -07:00
parent 6dd74bad6a
commit 653a086fea
14 changed files with 11 additions and 98 deletions

View File

@ -1,59 +1,27 @@
user www-data;
worker_processes auto;
pid /run/nginx.pid;
# include /etc/nginx/modules/*.conf;
events {
worker_connections 768;
# multi_accept on;
}
http {
##
# Basic Settings
##
sendfile on;
tcp_nopush on;
types_hash_max_size 2048;
# server_tokens off;
# server_names_hash_bucket_size 64;
# server_name_in_redirect off;
include /etc/nginx/mime.types;
default_type application/octet-stream;
##
# SSL Settings
##
# ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3; # Dropping SSLv3, ref: POODLE
# ssl_prefer_server_ciphers on;
##
# Logging Settings
##
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
##
# Gzip Settings
##
gzip on;
gzip_vary on;
gzip_proxied any;
gzip_comp_level 6;
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
# gzip_vary on;
# gzip_proxied any;
# gzip_comp_level 6;
# gzip_buffers 16 8k;
# gzip_http_version 1.1;
# gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
##
# Virtual Host Configs
##
# include /etc/nginx/conf.d/*.conf;
include /etc/nginx/sites/*;
}

View File

@ -1,8 +1,3 @@
server {
listen 80;
server_name client.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name client.tronnet.net;

View File

@ -1,8 +1,3 @@
server {
listen 80 default_server;
server_name *.tronnet.net;
return 301 https://tronnet.net;
}
server {
listen 443 ssl http2 default_server;
server_name *.tronnet.net;

View File

@ -1,8 +1,3 @@
server {
listen 80;
server_name tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name tronnet.net;

View File

@ -1,8 +1,3 @@
server {
listen 80;
server_name ldap.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name ldap.tronnet.net;

View File

@ -1,9 +1,3 @@
server {
listen 80;
server_name mail.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name mail.tronnet.net;

View File

@ -1,8 +1,3 @@
server {
listen 80;
server_name nextcloud.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name nextcloud.tronnet.net;

View File

@ -1,9 +1,3 @@
server {
listen 80;
server_name opns.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name opns.tronnet.net;

View File

@ -1,9 +1,3 @@
server {
listen 80;
server_name pve.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name pve.tronnet.net;

5
sites/redirect.conf Normal file
View File

@ -0,0 +1,5 @@
server {
listen 80 default_server;
server_name *.tronnet.net;
return 301 https://$host$request_uri;
}

View File

@ -1,9 +1,3 @@
server {
listen 80;
server_name root.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name root.tronnet.net;

View File

@ -1,8 +1,3 @@
server {
listen 80;
server_name status.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name status.tronnet.net;

View File

@ -1,8 +1,3 @@
server {
listen 80;
server_name wiki.tronnet.net;
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443 ssl http2;
server_name wiki.tronnet.net;

View File

@ -9,7 +9,6 @@ ssl_stapling on;
ssl_stapling_verify on;
resolver 8.8.8.8 8.8.4.4 valid=300s;
resolver_timeout 5s;
# add_header Strict-Transport-Security "max-age=31536000; includeSubdomains" always;
add_header X-Frame-Options SAMEORIGIN;
add_header X-Content-Type-Options nosniff;
add_header X-XSS-Protection "1; mode=block";