forked from Wavyzz/dolibarr-docker
30 lines
569 B
Nginx Configuration File
30 lines
569 B
Nginx Configuration File
server {
|
|
listen 80;
|
|
listen [::]:80;
|
|
|
|
server_name example.com www.example.com;
|
|
server_tokens off;
|
|
|
|
location /.well-known/acme-challenge/ {
|
|
root /var/www/certbot;
|
|
}
|
|
|
|
location / {
|
|
return 301 https://example.com$request_uri;
|
|
}
|
|
}
|
|
|
|
server {
|
|
root /srv/api/public;
|
|
|
|
listen 443 ssl http2;
|
|
server_name www.example.com;
|
|
|
|
ssl_certificate /etc/letsencrypt/live/example.com/fullchain.pem;
|
|
ssl_certificate_key /etc/letsencrypt/live/example.com/privkey.pem;
|
|
|
|
location / {
|
|
proxy_pass http://example.com:8181;
|
|
}
|
|
}
|