-
Notifications
You must be signed in to change notification settings - Fork 400
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add nginx reverse proxy to dev environment (#5745)
* chore: add nginx reverse proxy to dev environment * chore: replace settings_local in docker and backup old
- Loading branch information
Showing
10 changed files
with
118 additions
and
29 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
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 |
---|---|---|
|
@@ -18,5 +18,8 @@ services: | |
pgadmin: | ||
network_mode: service:db | ||
|
||
static: | ||
network_mode: service:db | ||
|
||
volumes: | ||
datatracker-vscode-ext: |
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
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,59 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Datatracker DEV</title> | ||
<style> | ||
body { | ||
background-color: #111; | ||
color: #FFF; | ||
font-family: Arial, Helvetica, sans-serif; | ||
text-align: center; | ||
padding: 50px; | ||
font-size: 16px; | ||
} | ||
img { | ||
height: 80px; | ||
} | ||
h1 { | ||
color: #CCC; | ||
} | ||
div { | ||
background-color: #222; | ||
border-radius: 10px; | ||
padding: 10px 50px; | ||
display: inline-block; | ||
} | ||
i { | ||
font-size: 64px; | ||
line-height: 16px; | ||
vertical-align: text-bottom; | ||
margin-right: 5px; | ||
} | ||
code { | ||
background-color: #444; | ||
padding: 3px 6px; | ||
border-radius: 5px; | ||
margin: 0 5px; | ||
} | ||
.mt { | ||
margin-top: 15px; | ||
} | ||
a { | ||
color: #31CCEC; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<img src="/_static/logos/ietf-inverted.svg" alt="IETF" /> | ||
<h1>Datatracker</h1> | ||
<h2>Could not connect to dev server.</h2> | ||
<div> | ||
<p>Is the datatracker server running?</p> | ||
<p class="mt">Using <strong>VS Code</strong>, open the <strong>Run and Debug</strong> tab on the left and click the <i>‣</i> symbol (Run Server) to start the server.</p> | ||
<p>Otherwise, run the command <code>ietf/manage.py runserver 0.0.0.0:8001</code> from the terminal.</p> | ||
</div> | ||
<p class="mt">For more information, check out the <a href="https://github.com/ietf-tools/datatracker/blob/main/docker/README.md" target="_blank">Datatracker Development in Docker</a> guide.</p> | ||
</body> | ||
</html> |
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,23 @@ | ||
server { | ||
listen 8000 default_server; | ||
listen [::]:8000 default_server; | ||
|
||
root /var/www/html; | ||
index index.html index.htm index.nginx-debian.html; | ||
|
||
server_name _; | ||
|
||
location /_static/ { | ||
proxy_pass http://localhost:80/; | ||
} | ||
|
||
location / { | ||
error_page 502 /502.html; | ||
proxy_pass http://localhost:8001/; | ||
} | ||
|
||
location /502.html { | ||
root /var/www/html; | ||
internal; | ||
} | ||
} |
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 |
---|---|---|
|
@@ -56,4 +56,4 @@ | |
|
||
DE_GFM_BINARY = '/usr/local/bin/de-gfm' | ||
|
||
STATIC_IETF_ORG = "http://localhost:8001" | ||
STATIC_IETF_ORG = "/_static" |
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,4 @@ | ||
#!/usr/bin/env bash | ||
|
||
apt-get update -y | ||
apt-get install -y nginx |