add dockerfile and paths
This commit is contained in:
parent
a0565f8b4c
commit
d45fcb79c1
0
basharin_sevastyan_lab_2/README.md
Normal file
0
basharin_sevastyan_lab_2/README.md
Normal file
5
basharin_sevastyan_lab_2/app1/Dockerfile
Normal file
5
basharin_sevastyan_lab_2/app1/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
FROM python:3.11
|
||||||
|
COPY . .
|
||||||
|
COPY var/data /var/data
|
||||||
|
COPY var/result /var/result
|
||||||
|
CMD ["python", "app.py"]
|
6
basharin_sevastyan_lab_2/app1/main.py
Normal file
6
basharin_sevastyan_lab_2/app1/main.py
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
def main():
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
main()
|
0
basharin_sevastyan_lab_2/app1/var/data/data.txt
Normal file
0
basharin_sevastyan_lab_2/app1/var/data/data.txt
Normal file
5
basharin_sevastyan_lab_2/app2/Dockerfile
Normal file
5
basharin_sevastyan_lab_2/app2/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
FROM python:3.11
|
||||||
|
COPY . .
|
||||||
|
COPY var/data /var/data
|
||||||
|
COPY var/result /var/result
|
||||||
|
CMD ["python", "app.py"]
|
6
basharin_sevastyan_lab_2/app2/main.py
Normal file
6
basharin_sevastyan_lab_2/app2/main.py
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
def main():
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
main()
|
0
basharin_sevastyan_lab_2/app2/var/data/data.txt
Normal file
0
basharin_sevastyan_lab_2/app2/var/data/data.txt
Normal file
19
basharin_sevastyan_lab_2/docker-compose.yaml
Normal file
19
basharin_sevastyan_lab_2/docker-compose.yaml
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
version: "3"
|
||||||
|
services:
|
||||||
|
worker-1:
|
||||||
|
build:
|
||||||
|
context: /app1
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
volumes:
|
||||||
|
- ./data:/var/data
|
||||||
|
- ./result:/var/result
|
||||||
|
|
||||||
|
worker-2:
|
||||||
|
depends_on:
|
||||||
|
- worker-1
|
||||||
|
build:
|
||||||
|
context: /app2
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
volumes:
|
||||||
|
- ./result:/var/data
|
||||||
|
- ./result:/var/result
|
Loading…
Reference in New Issue
Block a user