Compare commits

..

4 Commits

Author SHA1 Message Date
763d360be6 Merge pull request '2601b/docker' (#4) from 2601b/docker into main
All checks were successful
Flask Run Test / Flask-Run-Test (push) Successful in 9s
Reviewed-on: #4
2026-01-09 15:53:59 +09:00
Andrew K
f3f9979a0e improve docker environment
All checks were successful
Flask Run Test / Flask-Run-Test (push) Successful in 9s
2026-01-09 15:08:32 +09:00
Andrew K
bd93caa375 make sure flask server is able to be accessed from host, outside container
All checks were successful
Flask Run Test / Flask-Run-Test (push) Successful in 10s
2026-01-09 15:02:13 +09:00
Andrew K
a48abc3b53 create docker files
All checks were successful
Flask Run Test / Flask-Run-Test (push) Successful in 10s
2026-01-09 15:01:56 +09:00
3 changed files with 25 additions and 1 deletions

14
.dockerignore Normal file
View File

@@ -0,0 +1,14 @@
.idea
__pycache__
.git
.dockerignore
Dockerfile
*.md
db.json
users.json
test.py
update_db.py
logs
*.log
.vscode
uploads/

10
Dockerfile Normal file
View File

@@ -0,0 +1,10 @@
FROM python:3.9.5
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
COPY container/* .
RUN mkdir -p /app/uploads
EXPOSE 3133
CMD ["python", "app.py"]

2
app.py
View File

@@ -330,4 +330,4 @@ def download(code):
flash('Invalid code! Check if you typed the correct code, and for one-time codes, make sure nobody else entered the code before you did.', 'error') flash('Invalid code! Check if you typed the correct code, and for one-time codes, make sure nobody else entered the code before you did.', 'error')
return redirect(url_for('upload')) return redirect(url_for('upload'))
app.run(debug=True, port=3133) app.run(debug=True, port=3133, host='0.0.0.0')