version: '3' services: app: build: context: .. dockerfile: .devcontainer/Dockerfile depends_on: db: condition: service_healthy environment: APP_DOMAIN_NAME: localhost:3000 APP_PROTOCOL: http DEVISE_SECRET_KEY: secret GROWSTUFF_EMAIL: "noreply@test.growstuff.org" GROWSTUFF_FLICKR_KEY: secretkey GROWSTUFF_FLICKR_SECRET: secretsecret GROWSTUFF_SITE_NAME: "Growstuff (local)" RAILS_SECRET_TOKEN: supersecret volumes: - ../..:/workspaces:cached # Overrides default command so things don't shut down after the process ends. command: sleep infinity db: image: postgres:17 restart: unless-stopped volumes: - postgres-data:/var/lib/postgresql/data - ./create-db-user.sql:/docker-entrypoint-initdb.d/create-db-user.sql environment: POSTGRES_USER: postgres POSTGRES_DB: growstuff_dev POSTGRES_PASSWORD: postgres ports: - "5432:5432" healthcheck: test: ["CMD-SHELL", "pg_isready"] interval: 10s timeout: 5s retries: 5 volumes: postgres-data: certs: driver: local