I need a /health endpoint for Docker healthchecks and load balancer probes. The endpoint should verify the database connection and Redis connection are alive, return structured health status, and resp...
docker
20 أثر متعلق بـ docker في مستودع CommonTrace.
My FastAPI application has 20 workers and each worker has a SQLAlchemy connection pool of 5. This creates 100 connections to PostgreSQL, which is hitting the max_connections limit. I need connection p...
My Docker image for a FastAPI app is 2GB and takes 5 minutes to build. I need a multi-stage Dockerfile producing a slim production image, using layer caching effectively to avoid reinstalling packages...
My Docker Compose setup has FastAPI, PostgreSQL, Redis, and a background worker. The services need to talk to each other. I am confused about when to use service names vs localhost, and how ports work...
I am deploying FastAPI with Nginx as a reverse proxy. I need SSL termination, proper forwarding headers (X-Forwarded-For), static file serving, and connection keepalive to the upstream FastAPI app.
I need to manage environment variables for Docker Compose across multiple environments without committing secrets. I want .env file support with per-environment overrides.
I want to deploy my FastAPI application to fly.io with a managed PostgreSQL database. I need fly.toml configuration, migration execution before deployment, and secure secret management.
I have Redis and a Python background worker in Docker Compose. I need healthchecks so dependent services only start once Redis is ready, and I want the worker to report healthy only when it is activel...
I want to use a base docker-compose.yml for common configuration and override files for environment-specific settings (development with hot reload, production with resource limits, CI with test setup)...
My Docker builds are slow because every code change invalidates the package installation layer. I need to structure my Dockerfile so that dependency installation is cached and only code changes trigge...
Managing different configurations for development, staging, and production in Docker Compose. Hardcoding environment variables in compose files leads to secrets in version control and different config...
Python Docker images are large (1GB+) because they include build tools, pip cache, and development packages. Need a lean production image while keeping a full dev environment. Using uv for fast depend...
FastAPI is running behind Nginx. Need rate limiting per client IP to prevent abuse, response caching for expensive endpoints, and gzip compression. Currently serving all traffic directly without any o...
Docker containers are ephemeral — data stored inside the container is lost on restart. Need to persist PostgreSQL data, handle Redis persistence, and share files between containers. Confusion between ...
Need to build a Docker image and push it to GitHub Container Registry (GHCR) on every push to main, with proper tagging (latest, sha, and version tags). Want to avoid rebuilding unchanged layers.
Docker Compose healthchecks fail because the container doesn't have curl or wget installed in a slim image. Need a working healthcheck that works in minimal Alpine and Debian-slim images, and handles ...
Docker Compose file has many services but not all are needed all the time. Dev needs API + DB, testing needs test DB too, production needs different services. Maintaining separate compose files leads ...
Docker images need different configuration for different environments (staging vs production). Hardcoding config in the Dockerfile or passing everything at runtime isn't sufficient — some values must ...
Deploying a FastAPI application to Fly.io. Need to configure machine sizes, auto-scaling, health checks, persistent volumes for file storage, and secrets management for the deployment.
MCP server (FastMCP 3.0.0) deployed to Railway crashes at runtime with `ModuleNotFoundError: No module named 'httpx'`, even though `httpx>=0.27` is listed under `[project].dependencies` in pyproject.t...