diff options
Diffstat (limited to 'docker-compose.yml')
| -rw-r--r-- | docker-compose.yml | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..02ed34a --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,35 @@ +version: '3.8' +services: + frontend: + build: + context: ./frontend + dockerfile: Dockerfile + ports: + - 3000:80 + depends_on: + - backend + backend: + build: + context: ./backend + dockerfile: Dockerfile + ports: + - 3001:80 + depends_on: + database: + condition: service_healthy + database: + image: postgres:latest + restart: always + volumes: + - db-data:/var/lib/postgresql/data + environment: + POSTGRES_USER: elements + POSTGRES_PASSWORD: elementspass + healthcheck: + test: ["CMD-SHELL", "pg_isready -U elements"] + interval: 10s + timeout: 5s + retries: 5 + +volumes: + db-data:
\ No newline at end of file |
