Advertisement
Pandaaaa906

Untitled

Jun 1st, 2022
2,753
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Nginx 1.39 KB | None | 0 0
  1. # configuration of the server
  2. server {
  3.     # the port your site will be served on
  4.     listen      0.0.0.0:8805;  # TODO
  5.  
  6.     ssl_protocols        TLSv1 TLSv1.1 TLSv1.2;
  7.     ssl_ciphers          ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE;
  8.     ssl_prefer_server_ciphers  on;
  9.     ssl_session_cache    shared:SSL:10m;
  10.     ssl_session_timeout  10m;
  11.  
  12.     # the domain name it will serve for
  13.     server_name 127.0.0.1 192.168.* catou8 localhost 192.168.5.246 192.168.4.246 192.168.9.246;
  14.     charset     utf-8;
  15.  
  16.     root /secret_path/static;
  17.     # max upload size
  18.     client_max_body_size 75M;   # adjust to taste
  19.     location /.well-known/pki-validation/ {
  20.     }
  21.  
  22.     location /favicon.ico {
  23.         alias /secret_path/static/img/favicon.ico ;
  24.     }
  25.  
  26.     location /static {
  27.         alias /secret_path/static ;
  28.     }
  29.  
  30.     location /media {
  31.             alias /secret_path/media ;
  32.         }
  33.  
  34.     # Finally, send all non-media requests to the Django server.
  35.     location / {
  36.         proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  37.         proxy_set_header X-Forwarded-Proto $scheme;
  38.         proxy_set_header Host $http_host;
  39.         # we don't want nginx trying to do something clever with
  40.         # redirects, we set the Host: header above already.
  41.         proxy_redirect off;
  42.         proxy_buffering off;
  43.         proxy_pass http://web:8000;  # TODO
  44.     }
  45.  
  46. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement