-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #25 from fixpoint/azure-aci
ACI deployment
- Loading branch information
Showing
6 changed files
with
512 additions
and
121 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 |
---|---|---|
@@ -0,0 +1,53 @@ | ||
upstream django { | ||
server localhost:8000; | ||
} | ||
|
||
# タイムアウトの設定 | ||
proxy_connect_timeout 30; | ||
proxy_send_timeout 300; | ||
proxy_read_timeout 300; | ||
|
||
server { | ||
# HTTPの80番ポートを指定 | ||
listen 80; | ||
server_name 0.0.0.0; | ||
# Specify the default charset | ||
charset utf-8; | ||
|
||
# アップロードファイルサイズのチェックを行わない | ||
client_max_body_size 0; | ||
|
||
# djangoの静的ファイル(HTML、CSS、Javascriptなど)を管理 | ||
location /.static/ { | ||
alias /var/opt/kompira/html/; | ||
} | ||
# 静的ファイルへのアクセス以外は HTTPS にリダイレクト | ||
location / { | ||
return 301 https://$host$request_uri; | ||
} | ||
} | ||
|
||
server { | ||
listen 443 ssl; | ||
server_name 0.0.0.0; | ||
# Specify the default charset | ||
charset utf-8; | ||
|
||
# アップロードファイルサイズのチェックを行わない | ||
client_max_body_size 0; | ||
|
||
ssl_certificate /etc/nginx/ssl/server.crt; | ||
ssl_certificate_key /etc/nginx/ssl/server.key; | ||
# ssl_password_file /etc/nginx/ssl/server.password; | ||
|
||
# djangoの静的ファイル(HTML、CSS、Javascriptなど)を管理 | ||
location /.static/ { | ||
alias /var/opt/kompira/html/; | ||
} | ||
# プロキシ設定 | ||
# 実際はNginxのコンテナにアクセスしてるのをDjangoにアクセスしてるかのようにみせる | ||
location / { | ||
uwsgi_pass django; | ||
include /etc/nginx/uwsgi_params; | ||
} | ||
} |
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
Oops, something went wrong.