Initial commit

This commit is contained in:
Ataxya 2021-10-26 11:17:08 +02:00
parent 7e6a943bfe
commit 41b4852cbf
9 changed files with 51 additions and 2 deletions

5
api-backend/Dockerfile Normal file
View File

@ -0,0 +1,5 @@
FROM python:2.7
ADD api.py /
EXPOSE 8001
RUN pip install requests flask
CMD [ "python", "api.py"]

6
api-backend/Dockerfile~ Normal file
View File

@ -0,0 +1,6 @@
FROM python:2.7
ADD api.py /
EXPOSE 8001
RUN apt update
RUN pip install requests flask
CMD [ "python", "api.py"]

View File

@ -1,4 +1,4 @@
#!/usr/bin/python2.7
#!/usr/local/bin/python2.7
# coding: utf-8
# Author : Alexandre Jauneau

View File

@ -0,0 +1 @@

7
api-frontend/Dockerfile Normal file
View File

@ -0,0 +1,7 @@
FROM python:2.7
ADD api.py /
ENV API_BACKEND_URL=185.119.254.201
ENV API_BACKEND_PORT=8001
EXPOSE 8000
RUN pip install requests flask
CMD [ "python", "api.py"]

7
api-frontend/Dockerfile~ Normal file
View File

@ -0,0 +1,7 @@
FROM python:2.7
ADD api.py /
ENV API_BACKEND_URL=127.0.0.1
ENV API_BACKEND_PORT=8001
EXPOSE 8000
RUN pip install requests flask
CMD [ "python", "api.py"]

View File

@ -1,4 +1,4 @@
#!/usr/bin/python2.7
#!/usr/local/bin/python2.7
# coding: utf-8
# Author : Alexandre Jauneau

13
docker-compose.yml Normal file
View File

@ -0,0 +1,13 @@
version: "3.3"
services:
back-end:
build: api-backend/
ports:
- "8001:8001"
restart: always
front-end:
build: api-frontend/
ports:
- "8000:8000"
depends_on:
- back-end

10
docker-compose.yml~ Normal file
View File

@ -0,0 +1,10 @@
version: "3.3"
services:
backend:
build: api-backend/
ports:
- "8001:8001"
front-end:
build: api-frontend/
ports:
- "8000:8000"