# compose.yaml name: neuronpedia services: webapp: image: neuronpedia-webapp:latest build: context: .. dockerfile: apps/webapp/Dockerfile target: runner args: ENV_FILE: ${ENV_FILE:-.env.localhost} CUSTOM_CA_BUNDLE: ${CUSTOM_CA_BUNDLE:-.nocustomca} ports: - "3000:3000" env_file: - ${ENV_FILE:-../.env.localhost} depends_on: db-init: condition: service_completed_successfully db-init: image: neuronpedia-db-init:latest build: context: .. dockerfile: apps/webapp/Dockerfile target: db-init args: ENV_FILE: ${ENV_FILE:-.env.localhost} CUSTOM_CA_BUNDLE: ${CUSTOM_CA_BUNDLE:-.nocustomca} restart: "no" environment: - POSTGRES_URL_NON_POOLING=${POSTGRES_URL_NON_POOLING} - POSTGRES_PRISMA_URL=${POSTGRES_PRISMA_URL} - POSTGRES_USER=${POSTGRES_USER} - POSTGRES_PASSWORD=${POSTGRES_PASSWORD} - POSTGRES_DB=${POSTGRES_DB} depends_on: postgres: condition: service_healthy postgres: image: pgvector/pgvector:pg15 healthcheck: test: ["CMD-SHELL", "pg_isready -U postgres"] interval: 5s timeout: 5s retries: 5 environment: - POSTGRES_URL_NON_POOLING=${POSTGRES_URL_NON_POOLING} - POSTGRES_PRISMA_URL=${POSTGRES_PRISMA_URL} - POSTGRES_USER=${POSTGRES_USER} - POSTGRES_PASSWORD=${POSTGRES_PASSWORD} - POSTGRES_DB=${POSTGRES_DB} ports: - "5432:5432" volumes: - postgres_data:/var/lib/postgresql/data - ../apps/webapp/prisma/pgvector-init:/docker-entrypoint-initdb.d inference: platform: linux/amd64 image: neuronpedia-inference:latest build: context: .. dockerfile: apps/inference/Dockerfile args: BUILD_TYPE: ${BUILD_TYPE:-nocuda} # Use nocuda by default, override with BUILD_TYPE=cuda CUDA_VERSION: "12.1.0" UBUNTU_VERSION: "22.04" CUSTOM_CA_BUNDLE: ${CUSTOM_CA_BUNDLE:-.nocustomca} ports: - "5002:5002" env_file: - ${ENV_FILE:-${MODEL_SOURCESET:+.env.inference.${MODEL_SOURCESET}}.env} environment: - HF_TOKEN=${HF_TOKEN} - SECRET=${INFERENCE_SERVER_SECRET} - SENTRY_DSN=${SENTRY_DSN_INFERENCE} autointerp: platform: linux/amd64 image: neuronpedia-autointerp:latest build: context: .. dockerfile: apps/autointerp/Dockerfile args: BUILD_TYPE: ${BUILD_TYPE:-nocuda} CUDA_VERSION: "12.1.0" UBUNTU_VERSION: "22.04" ports: - "5003:5003" env_file: - ${ENV_FILE:-.env} environment: - HF_TOKEN=${HF_TOKEN} - SECRET=${AUTOINTERP_SERVER_SECRET} - SENTRY_DSN=${SENTRY_DSN_AUTOINTERP} graph: platform: linux/amd64 image: neuronpedia-graph:latest build: context: .. dockerfile: apps/graph/Dockerfile args: BUILD_TYPE: ${BUILD_TYPE:-nocuda} CUDA_VERSION: "12.1.0" UBUNTU_VERSION: "22.04" ports: - "5004:5004" env_file: - ${ENV_FILE:-.env} environment: - HF_TOKEN=${HF_TOKEN} - SECRET=${GRAPH_SERVER_SECRET} graph-crm: platform: linux/amd64 image: neuronpedia-graph-crm:latest build: context: .. dockerfile: apps/graph-crm/Dockerfile args: BUILD_TYPE: ${BUILD_TYPE:-nocuda} CUDA_VERSION: "12.1.0" UBUNTU_VERSION: "22.04" ports: - "5005:5005" env_file: - ${ENV_FILE:-.env} environment: - HF_TOKEN=${HF_TOKEN} - SECRET=${GRAPH_SERVER_SECRET} volumes: postgres_data: networks: default: name: neuronpedia-network