Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Luiz Irber
committed
Feb 15, 2018
1 parent
9ce305d
commit ebdeae4
Showing
5 changed files
with
71 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,7 @@ | ||
**/__pycache__ | ||
redis/ | ||
env.production | ||
iam/ | ||
integration/ | ||
letsencrypt_certs/ | ||
*.swp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
FROM nginx:stable | ||
COPY nginx.conf /etc/nginx/ | ||
COPY wort.conf /etc/nginx/conf.d/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,31 @@ | ||
user nginx; | ||
worker_processes 1; | ||
|
||
error_log /var/log/nginx/error.log warn; | ||
pid /var/run/nginx.pid; | ||
|
||
|
||
events { | ||
worker_connections 1024; | ||
} | ||
|
||
|
||
http { | ||
server { | ||
listen 80; | ||
server_name wort.oxli.org; | ||
include /etc/nginx/mime.types; | ||
default_type application/octet-stream; | ||
|
||
location /.well-known/acme-challenge/ { | ||
root /var/www/letsencrypt; | ||
} | ||
log_format main '$remote_addr - $remote_user [$time_local] "$request" ' | ||
'$status $body_bytes_sent "$http_referer" ' | ||
'"$http_user_agent" "$http_x_forwarded_for"'; | ||
|
||
location / { | ||
return 301 https://$host$request_uri; | ||
} | ||
} | ||
access_log /var/log/nginx/access.log main; | ||
|
||
server { | ||
listen 443 ssl; | ||
sendfile on; | ||
#tcp_nopush on; | ||
|
||
ssl_certificate certs/live/wort.oxli.org/fullchain.pem; | ||
ssl_certificate_key certs/live/wort.oxli.org/privkey.pem; | ||
keepalive_timeout 65; | ||
|
||
server_name wort.oxli.org; | ||
#gzip on; | ||
|
||
location / { | ||
proxy_pass http://wort.oxli.org; | ||
} | ||
} | ||
include /etc/nginx/conf.d/*.conf; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
map $http_upgrade $connection_upgrade { | ||
default upgrade; | ||
'' close; | ||
} | ||
|
||
server { | ||
listen 80; | ||
listen [::]:80; | ||
server_name wort.oxli.org; | ||
|
||
location /.well-known/acme-challenge/ { | ||
allow all; | ||
root /var/www/letsencrypt/; | ||
} | ||
|
||
location / { | ||
return 301 https://$host$request_uri; | ||
} | ||
} | ||
|
||
server { | ||
listen 443 ssl; | ||
|
||
ssl_certificate certs/live/wort.oxli.org/fullchain.pem; | ||
ssl_certificate_key certs/live/wort.oxli.org/privkey.pem; | ||
|
||
server_name wort.oxli.org; | ||
|
||
resolver 127.0.0.11; | ||
set $backends web; | ||
|
||
location / { | ||
proxy_pass http://web:5000; | ||
} | ||
} |