Files
EpicNext-Cms/scripts
openhands 8ec3df541e
Gitea Actions Runner Test / test-job (push) Successful in 2s
CI / check (push) Successful in 30s
CI / tests-integration (push) Successful in 1m43s
CI / tests-unit (push) Successful in 1m47s
CI / tests-ui (push) Successful in 2m33s
CI / preflight (push) Skipped
CI / deploy (push) Failing after 1m30s
fix(deploy): name the container blocking a port and silence phantom cleanup
Two follow-ups from the blocked deploy.

The rollback path called `docker logs` and `docker rm -f` on the candidate
unconditionally. When the port check refuses to start it, the container was
never created, so both printed "No such container: epicnext-cms-app" — noise
that looked like a second, unrelated failure and buried the real message.
Both calls are now guarded by `docker inspect`.

assert_port_free() now reports which container holds the port and flags it when
it is not a blue/green slot this script manages. The previous output listed
every container and said only "port already in use", which is a dead end: on
this host the holder is `epicnext-cms` (a `docker compose up` replica on port
3002), while the deploy manages slot A as `epicnext-cms-app`. The names differ
because docker-compose.yml pins `container_name: epicnext-cms` for the `cms`
service; slot B happens to match, which is why 3003 deploys fine and 3002 never
can. The message now names the squatter, explains that live traffic is
unaffected, and gives the next action.

Deploy simulation: 26 passed.
2026-10-03 18:37:12 +02:00
..
2026-07-13 21:57:41 +02:00
2026-08-25 22:26:05 +02:00
2026-07-13 21:57:41 +02:00
2026-07-13 21:57:41 +02:00

Scripts Documentation

This directory contains utility scripts for managing the EpicNext-Cms project.

Scripts Overview

Script Description
dashboard.sh Main interactive menu to run all other scripts.
deploy.sh Safely redeploys the application by freeing the port first.
logs.sh View logs for cms and mariadb services.
backup.sh Creates a database backup in /backups.
db-restore.sh Restores a database backup.
db-optimize.sh Optimizes database tables.
docker-prune.sh Cleans up unused Docker resources.
verify-deploy.sh Checks if the CMS is reachable after deployment.
check-env.sh Validates .env against .env.example.
check-security.sh Runs pnpm audit and checks for image updates.
monitor.sh Shows system disk/container resource usage.
perf-report.sh Runs performance profiling.
setup-dev.sh Configures development environment.
check-updates.sh Checks for package and image updates.
maintenance.sh Toggles maintenance mode flag.
doctor.sh Runs a system diagnostic report.
setup-cron.sh Configures automated cron jobs.
alert.sh Sends notifications to a configured webhook.

Usage

Run any script directly, or use the dashboard:

./scripts/dashboard.sh