#SVTH-575 - Ajustes no repositório para instalação.

This commit is contained in:
2026-07-20 11:37:26 -03:00
parent c2198960c4
commit c26ff16eab

View File

@@ -4,6 +4,7 @@ ENV_FILE = .env.$(ENV)
PROJECT_NAME = attendancesystem-$(ENV)
NETWORK_NAME = attendancesystem-network
APP_SERVICES = suite-api users-api reports-api attendancesystem-api config-generator attendancesystem-app reports-app users-app suite-app
.PHONY: infra app install update restart reset-network nuke nuke-project
@@ -80,16 +81,26 @@ restart:
docker restart $$(docker ps -q)
# ===============================
# 🔄 Atualizar projeto
# 🔄 Atualizar projeto (apenas APP)
# ===============================
update:
@echo "🛑 Parando e removendo containers do profile 'app' ($(PROJECT_NAME))..."
@echo "🛑 Parando containers do profile 'app' ($(PROJECT_NAME))..."
docker compose \
--project-name $(PROJECT_NAME) \
--env-file $(ENV_FILE) \
--profile infra \
--profile app \
-f $(COMPOSE_FILE) \
down --remove-orphans
stop $(APP_SERVICES)
@echo "🗑️ Removendo containers do profile 'app' ($(PROJECT_NAME))..."
docker compose \
--project-name $(PROJECT_NAME) \
--env-file $(ENV_FILE) \
--profile infra \
--profile app \
-f $(COMPOSE_FILE) \
rm -f $(APP_SERVICES)
@echo "🖼️ Removendo imagens antigas do projeto (seventhltda)..."
- docker images --format '{{.Repository}}:{{.Tag}}' | grep '^seventhltda/' | xargs -r docker rmi -f 2>/dev/null || true