Add Docker support for client and server with docker-compose configuration

This commit is contained in:
Lukian 2025-01-21 11:48:18 +01:00
parent 07f9744a14
commit 3ec5483b3c
3 changed files with 31 additions and 0 deletions

5
RSA/client/dockerfile Normal file
View file

@ -0,0 +1,5 @@
FROM python:alpine
WORKDIR /app
COPY . .
RUN pip install -r requirements.txt
CMD ["python", "client.py"]

19
RSA/docker-compose.yml Normal file
View file

@ -0,0 +1,19 @@
services:
web:
build: ./server
container_name: web
ports:
- 80:80
- 5000:5000
networks:
- mynetwork
client:
build: ./client
container_name: client
networks:
- mynetwork
networks:
mynetwork:
external: false

7
RSA/server/dockerfile Normal file
View file

@ -0,0 +1,7 @@
FROM python:alpine
WORKDIR /app
COPY . .
RUN pip install -r requirements.txt
EXPOSE 80
EXPOSE 5000
CMD ["python", "__init__.py"]