-
Notifications
You must be signed in to change notification settings - Fork 20
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 #620 from IATI/django-deploy
Django deploy
- Loading branch information
Showing
5 changed files
with
36 additions
and
3 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,2 @@ | ||
data | ||
out |
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 @@ | ||
FROM python:3.12-bookworm | ||
|
||
WORKDIR /work/IATI-Dashboard/dashboard | ||
|
||
COPY requirements.txt /work/IATI-Dashboard/requirements.txt | ||
|
||
RUN git config --global --add safe.directory /work/IATI-Stats/data | ||
|
||
RUN pip install -r /work/IATI-Dashboard/requirements.txt | ||
|
||
COPY . /work/IATI-Dashboard | ||
|
||
# 2024-03-20: Emergency fix | ||
# We were seeing cert errors inside the docker container after a new Lets Encrypt was issued. | ||
# | ||
# We know there are changes coming about root certificates and the error may be caused by that: | ||
# https://blog.cloudflare.com/upcoming-lets-encrypt-certificate-chain-change-and-impact-for-cloudflare-customers | ||
# | ||
# I tried installing the LE root cert's manually but that didn't work. | ||
# As live is broken for now we need this emergency fix, but we should remove it in the future. | ||
RUN echo "check_certificate=off" > /root/.wgetrc | ||
|
||
CMD ["gunicorn", "--bind", "0.0.0.0:8000", "--timeout", "120", "ui.wsgi:application"] |
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,4 +1,5 @@ | ||
django | ||
gunicorn | ||
flask | ||
frozen-flask | ||
jinja2 | ||
|
@@ -11,4 +12,4 @@ lxml | |
requests | ||
markupsafe | ||
itsdangerous | ||
tqdm | ||
tqdm |
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