server {
listen 80;
listen [::]:80;
server_name 88888.com;
rewrite ^ https://888888.com$request_uri? permanent;
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
ssl_certificate /etc/ssl/8888888.crt;
ssl_certificate_key /etc/ssl/8888888.key;
include /etc/nginx/snippets/ssl;
server_name 88888888.com;
if ($host !~* ^(88888888.com)$ ){return 444;}
if ($request_method !~ ^(GET|HEAD|POST)$ ){return 444;}
access_log /var/log/nginx/stp.access.log;
error_log /var/log/nginx/stp.error.log;
client_max_body_size 64m;
location / {
uwsgi_pass unix:///tmp/stp.sock;
include uwsgi_params;
uwsgi_param UWSGI_SCHEME $scheme;
uwsgi_param SERVER_SOFTWARE nginx/$nginx_version;
}
location /static/ {
alias /home/alx/stp/static/;
}
location /media/ {
alias /home/alx/stp/static/media/;
}
}
server {
listen 80;
listen [::]:80;
server_name www.88888888.com;
rewrite ^ https://www.88888888.com$request_uri? permanent;
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
ssl_certificate /etc/ssl/8888888.crt;
ssl_certificate_key /etc/ssl/8888888.key;
include /etc/nginx/snippets/ssl;
server_name www.888888888.com;
access_log /var/log/nginx/stp.access.log;
error_log /var/log/nginx/stp.error.log;
client_max_body_size 64m;
location / {
uwsgi_pass unix:///tmp/stp.sock;
include uwsgi_params;
uwsgi_param UWSGI_SCHEME $scheme;
uwsgi_param SERVER_SOFTWARE nginx/$nginx_version;
}
location /static/ {
alias /home/alx/stp/static/;
}
location /media/ {
alias /home/alx/stp/static/;
}
}
server {
listen 80;
listen [::]:80;
server_name *.888888888.com;
rewrite ^ https://*.888888888.com$request_uri? permanent;
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
ssl_certificate /etc/ssl/8888888888.crt;
ssl_certificate_key /etc/ssl/88888888.key;
include /etc/nginx/snippets/ssl;
server_name *.8888888888.com;
access_log /var/log/nginx/stp.access.log;
error_log /var/log/nginx/stp.error.log;
client_max_body_size 64m;
location / {
uwsgi_pass unix:///tmp/landing.sock;
include uwsgi_params;
uwsgi_param UWSGI_SCHEME $scheme;
uwsgi_param SERVER_SOFTWARE nginx/$nginx_version;
}
location /static/ {
alias /home/alx/stp/static/;
}
location /media/ {
alias /home/alx/stp/static/;
}
}
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN
tcp6 0 0 :::80 :::* LISTEN
unix 2 [ ACC ] STREAM LISTENING 28092 /run/user/0/systemd/private
unix 2 [ ACC ] STREAM LISTENING 15080 /tmp/stp.sock
from django.views.decorators.cache import never_cache
@never_cache