From d8f9aae9f802620f470d2cea7febcee2b64cbb23 Mon Sep 17 00:00:00 2001 From: Xanders25 Date: Wed, 25 Dec 2024 17:27:43 +0200 Subject: [PATCH] =?UTF-8?q?=D0=9E=D0=B1=D0=BD=D0=BE=D0=B2=D0=B8=D1=82?= =?UTF-8?q?=D1=8C=20docker-compose.yml?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker-compose.yml | 30 +++++++++--------------------- 1 file changed, 9 insertions(+), 21 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index afb5e76..4ccb866 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,25 +1,13 @@ -services: - git_cloner: - image: alpine/git - volumes: - - /data/py:/repo - command: > - sh -c " - if [ ! -d /repo/.git ]; then - git clone https://git.xander.cx.ua/Xanders25/test_compos.git /repo && - echo 'Repository cloned'; - else - echo 'Repository already exists'; - fi; - " +version: '3.8' - app: +services: + flask-app: build: - context: /data/py - dockerfile: Dockerfile - working_dir: /app - command: python app.py + context: . + dockerfile: Dockerfile ports: - "5000:5000" - depends_on: - - git_cloner + volumes: + - .:/app + environment: + - FLASK_ENV=development