Adding force recreate when no-cache

This commit is contained in:
Finley Ghosh 2025-12-08 21:47:54 +11:00
parent 34747336dd
commit 5db8451f2c
2 changed files with 2 additions and 2 deletions

View file

@ -79,7 +79,7 @@ ENVEOF
if [[ "$USE_CACHE" == "false" ]]; then
echo "Building and starting docker compose for production (no cache)..."
docker compose --env-file .env.prod -f docker-compose.prod.yml build --no-cache
docker compose --env-file .env.prod -f docker-compose.prod.yml up -d --remove-orphans
docker compose --env-file .env.prod -f docker-compose.prod.yml up -d --force-recreate --remove-orphans
else
echo "Building and starting docker compose for production (using cache)..."
docker compose --env-file .env.prod -f docker-compose.prod.yml build

View file

@ -70,7 +70,7 @@ ENVEOF
if [[ "$USE_CACHE" == "false" ]]; then
echo "Building and starting docker compose for staging (no cache)..."
docker compose -f docker-compose.stg.yml build --no-cache
docker compose -f docker-compose.stg.yml up -d --remove-orphans
docker compose -f docker-compose.stg.yml up -d --force-recreate --remove-orphans
else
echo "Building and starting docker compose for staging (using cache)..."
docker compose -f docker-compose.stg.yml build