forked from linux/WebHosting
e0b97741de
Signed-off-by: Basil Bruhn <basil.bruhn@psi.ch>
28 lines
595 B
Plaintext
28 lines
595 B
Plaintext
server {
|
|
listen 80;
|
|
server_name sls2.psi.ch;
|
|
|
|
return 301 https://$host$request_uri;
|
|
}
|
|
|
|
server {
|
|
listen 443 ssl;
|
|
server_name sls2.psi.ch;
|
|
|
|
ssl_certificate /etc/nginx/certs/sls2.psi.ch.crt;
|
|
ssl_certificate_key /etc/nginx/private/sls2.psi.ch.key;
|
|
|
|
access_log /var/log/nginx/sls2.access.log;
|
|
error_log /var/log/nginx/sls2.error.log;
|
|
|
|
location / {
|
|
proxy_pass http://apache_app:80;
|
|
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
|
}
|
|
}
|
|
|