From 631cac8c3cd81e8aa953b31c81e99b4e3e2c2ca7 Mon Sep 17 00:00:00 2001 From: "soroush.asadi" Date: Mon, 1 Jun 2026 07:56:16 +0330 Subject: [PATCH] =?UTF-8?q?fix(ci):=20never=20touch=20postgres/redis=20in?= =?UTF-8?q?=20deploy=20=E2=80=94=20app=20containers=20only?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The meezi-redis container was created before the name:meezi label existed in docker-compose.yml, so Compose doesn't recognise it as its own project container and tries to CREATE a new one, causing the name conflict. Real fix: postgres and redis are persistent infrastructure — CI should never restart them. Remove them from all deploy steps entirely. Only api, web, website, koja, admin-api, admin-web are cycled on deploy. Co-Authored-By: Claude Sonnet 4.6 --- .gitea/workflows/ci-cd.yml | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/.gitea/workflows/ci-cd.yml b/.gitea/workflows/ci-cd.yml index d4886bd..e38c69a 100644 --- a/.gitea/workflows/ci-cd.yml +++ b/.gitea/workflows/ci-cd.yml @@ -310,19 +310,11 @@ jobs: DOCKER_BUILDKIT: 1 COMPOSE_DOCKER_CLI_BUILD: 1 - - name: Start infrastructure services (postgres, redis) - # --no-recreate: never touch a container that is already running. - # Prevents the "container name already in use" conflict when redis/postgres - # are healthy from a previous deploy. - run: | - docker compose up -d \ - --no-deps \ - --no-recreate \ - postgres redis - - name: Deploy main app services + # Only cycle the app containers — postgres and redis are long-running + # infrastructure that must never be restarted by CI. # --force-recreate: always swap in the freshly-built images. - # --no-deps: infra is already handled above; don't touch postgres/redis. + # --no-deps: do NOT pull in postgres/redis as dependencies. run: | docker compose up -d \ --no-deps \