version: '3' services: postgres: image: kartoza/postgis:12.0 hostname: postgres ports: - 5432:5432 container_name: community-board-db-postgres env_file: - .env server: build: ./server ports: - 5000:5000 volumes: - ./server/src:/server/src container_name: community-board-db-server depends_on: - postgres environment: WAIT_HOSTS: postgres:5432 WAIT_AFTER_HOSTS: 1 env_file: - .env client: build: ./client ports: - 3000:3000 container_name: community-board-db-client volumes: #for dev only - ./client/src:/client/src depends_on: - server environment: API_HOST: http://localhost:5000 env_file: - .env