DevOps & CI/CD
Bug Report
Docker build reinstalls every dependency on each commit: COPY order and cache busting
Every push to our FastAPI service spent seven minutes reinstalling the same Python packages. COPY . . ran before pip install, and a missing .dockerignore let .git changes bust the cache. Reordering layers and a cache mount cut builds to 50 seconds.