generated from orchestr7/react-kotlin-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvhosts_nginx.conf
85 lines (84 loc) · 2.8 KB
/
vhosts_nginx.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
server {
server_name posidata.ru www.posidata.ru;
charset off;
index index.php index.html;
disable_symlinks if_not_owner from=$root_path;
include /etc/nginx/vhosts-includes/*.conf;
include /etc/nginx/vhosts-resources/posidata.ru/*.conf;
access_log /var/www/httpd-logs/posidata.ru.access.log;
error_log /var/www/httpd-logs/posidata.ru.error.log notice;
ssi on;
set $root_path /var/www/www-root/data/www/posidata.ru;
root $root_path;
location / {
location ~ [^/]\.ph(p\d*|tml)$ {
try_files /does_not_exists @fallback;
}
location ~* ^.+\.(jpg|jpeg|gif|png|svg|js|css|mp3|ogg|mpe?g|avi|zip|gz|bz2?|rar|swf|webp|woff|woff2)$ {
try_files $uri $uri/ @fallback;
}
location / {
try_files /does_not_exists @fallback;
}
}
location /api/ {
proxy_pass http://127.0.0.1:8081/api/;
}
location @fallback {
include /etc/nginx/vhosts-resources/posidata.ru/dynamic/*.conf;
proxy_pass http://127.0.0.1:8080;
proxy_redirect http://127.0.0.1:8080 /;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Port $server_port;
access_log off;
}
return 301 https://$host:443$request_uri;
listen 194.58.107.28:80;
}
server {
server_name posidata.ru www.posidata.ru;
ssl_certificate "/var/www/httpd-cert/www-root/posidata.ru_le2.crtca";
ssl_certificate_key "/var/www/httpd-cert/www-root/posidata.ru_le2.key";
ssl_ciphers EECDH:+AES256:-3DES:RSA+AES:!NULL:!RC4;
ssl_prefer_server_ciphers on;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3;
add_header Strict-Transport-Security "max-age=31536000;";
ssl_dhparam /etc/ssl/certs/dhparam4096.pem;
charset off;
index index.php index.html;
disable_symlinks if_not_owner from=$root_path;
include /etc/nginx/vhosts-includes/*.conf;
include /etc/nginx/vhosts-resources/posidata.ru/*.conf;
access_log /var/www/httpd-logs/posidata.ru.access.log;
error_log /var/www/httpd-logs/posidata.ru.error.log notice;
ssi on;
set $root_path /var/www/www-root/data/www/posidata.ru;
root $root_path;
location / {
location ~ [^/]\.ph(p\d*|tml)$ {
try_files /does_not_exists @fallback;
}
location ~* ^.+\.(jpg|jpeg|gif|png|svg|js|css|mp3|ogg|mpe?g|avi|zip|gz|bz2?|rar|swf|webp|woff|woff2)$ {
try_files $uri $uri/ @fallback;
}
location / {
try_files /does_not_exists @fallback;
}
}
location /api/ {
proxy_pass http://127.0.0.1:8081/api/;
}
location @fallback {
include /etc/nginx/vhosts-resources/posidata.ru/dynamic/*.conf;
proxy_pass http://127.0.0.1:8080;
proxy_redirect http://127.0.0.1:8080 /;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Port $server_port;
access_log off;
}
listen 194.58.107.28:443 ssl;
}