version: '3.8' # Unique Compose project name so this repo's devcontainer doesn't collide with # other model-* clones (which all live in .devcontainer/backend/ and would # otherwise default to the same project name "backend", clobbering each other). name: landlord-backend services: model-backend: build: context: ../.. dockerfile: .devcontainer/backend/Dockerfile args: USER_UID: ${UID:-1000} USER_GID: ${GID:-1000} command: sleep infinity ports: # Host port left unspecified so Docker assigns a free one — lets multiple # worktrees of this repo run at once without colliding. VS Code's # forwardPorts (in devcontainer.json) forwards container :8000 to your machine. - "8000" # noVNC desktop for the hyde Elmhurst automation (scripts/hyde/start_viewer.sh). # Dynamic host port like 8000; VS Code forwardPorts maps container :6080 to # a stable localhost:6080 on your machine. - "6080" volumes: - ../../:/workspaces/model - ~/.gitconfig:/home/vscode/.gitconfig:ro # GitHub CLI auth from host (created by `gh auth login`). Used by the # postCreate skill installer to clone private Hestia-Homes repos. - ~/.config/gh:/home/vscode/.config/gh:ro environment: - SSH_AUTH_SOCK=${SSH_AUTH_SOCK:-} # Fallback HTTPS auth if ~/.config/gh isn't present on the host. - GITHUB_TOKEN=${GITHUB_TOKEN:-} networks: - backend-net - shared-dev db: image: postgres:17.4 restart: unless-stopped ports: # Dynamic host port (see model-backend above) so a second worktree's db # doesn't collide on 5432. Reach it from inside the container via host # "db:5432"; from your machine, use the forwarded port VS Code reports. - "5432" environment: - PGDATABASE=tech_team_local_db - POSTGRES_USER=postgres - POSTGRES_PASSWORD=makingwarmerhomes volumes: - postgres-data-two:/var/lib/postgresql/data networks: - backend-net networks: backend-net: driver: bridge shared-dev: external: true volumes: postgres-data-two: