nginx + dockerfile update

This commit is contained in:
tmshv committed 2019-08-03 19:03:39 +03:00
1 parent 1b77f6b2de
commit fee7a4f6da
2 files changed
+54 -65

No files matched your search

+12 -44
View File
@@ -1,48 +1,16 @@
server {
listen 443 ssl;
charset utf-8;
server_name art.shlisselburg.org;
ssl_certificate /etc/letsencrypt/live/art.shlisselburg.org/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/art.shlisselburg.org/privkey.pem;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
ssl_ciphers AES256+EECDH:AES256+EDH:!aNULL;
location / {
proxy_pass http://hudozka;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $remote_addr;
}
error_log /var/log/nginx/art.shburg.error.log;
access_log /var/log/nginx/art.shburg.access.log;
}
server {
listen 80;
server_name art.shlisselburg.org art.shburg.org;
location ^~ /.well-known/acme-challenge {
root /home/hoster/www/art.shburg.org/public;
}
listen 80;
server_name localhost;
charset utf-8;
location / {
return 301 https://art.shlisselburg.org$request_uri;
root /usr/share/nginx/html;
index index.html index.htm;
try_files $uri $uri.html $uri/index.html =404;
}
}
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
upstream hudozka {
server localhost:1800;
location = /50x.html {
root /usr/share/nginx/html;
}
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
}