diff --git a/gitea-mirror/.claude/skills/gitea-mirror-maintenance/SKILL.md b/.claude/skills/gitea-mirror-maintenance/SKILL.md similarity index 97% rename from gitea-mirror/.claude/skills/gitea-mirror-maintenance/SKILL.md rename to .claude/skills/gitea-mirror-maintenance/SKILL.md index f68bad4..f4821d0 100644 --- a/gitea-mirror/.claude/skills/gitea-mirror-maintenance/SKILL.md +++ b/.claude/skills/gitea-mirror-maintenance/SKILL.md @@ -1,12 +1,12 @@ --- name: gitea-mirror-maintenance -description: Detect and clean up failed, broken, or empty Gitea mirror repositories in the Coolify-deployed gitea + gitea-mirror stack, using tea and the gitea-mirror API. Use when the user asks to check mirror health, find failed or empty repos, investigate why a mirror did not sync or clone, delete broken mirror repos, delete archived copies of the user's own deleted repos, clean up duplicates left by renamed, transferred or re-cased GitHub repos, reclaim disk space from partial clones, re-mirror repos that failed, or run routine mirror upkeep. Not for Gitea setup, upgrades, or deployment problems — those belong to the service's compose definition. +description: Detect and clean up failed, broken, or empty Gitea mirror repositories in the Coolify-deployed gitea + gitea-mirror stack, using tea and the gitea-mirror API. Use when the user asks to check mirror health, find failed or empty repos, investigate why a mirror did not sync or clone, delete broken mirror repos, delete archived copies of the user's own deleted repos, clean up duplicates left by renamed, transferred or re-cased GitHub repos, reclaim disk space from partial clones, re-mirror repos that failed, or run routine mirror upkeep. Not for Gitea setup, upgrades, or deployment problems — those belong to `gitea-mirror/compose.yml`. --- # Gitea Mirror Maintenance -Maintain the `gitea` + `gitea-mirror` stack deployed by this directory's -`compose.yml` on Coolify: find mirror repositories whose pull failed, classify +Maintain the `gitea` + `gitea-mirror` stack deployed by +`gitea-mirror/compose.yml` on Coolify: find mirror repositories whose pull failed, classify each failure, then clean up only what is safe to delete. **Scope.** Mirror health auditing and cleanup only. Not Gitea first-run setup, diff --git a/gitea-mirror/.claude/skills/gitea-mirror-maintenance/references/failure-taxonomy.md b/.claude/skills/gitea-mirror-maintenance/references/failure-taxonomy.md similarity index 100% rename from gitea-mirror/.claude/skills/gitea-mirror-maintenance/references/failure-taxonomy.md rename to .claude/skills/gitea-mirror-maintenance/references/failure-taxonomy.md diff --git a/gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-archived-repos.sh b/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-archived-repos.sh similarity index 100% rename from gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-archived-repos.sh rename to .claude/skills/gitea-mirror-maintenance/scripts/cleanup-archived-repos.sh diff --git a/gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-failed-mirrors.sh b/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-failed-mirrors.sh similarity index 100% rename from gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-failed-mirrors.sh rename to .claude/skills/gitea-mirror-maintenance/scripts/cleanup-failed-mirrors.sh diff --git a/gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-renamed-repos.sh b/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-renamed-repos.sh similarity index 100% rename from gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/cleanup-renamed-repos.sh rename to .claude/skills/gitea-mirror-maintenance/scripts/cleanup-renamed-repos.sh diff --git a/gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/detect-failed-mirrors.sh b/.claude/skills/gitea-mirror-maintenance/scripts/detect-failed-mirrors.sh similarity index 100% rename from gitea-mirror/.claude/skills/gitea-mirror-maintenance/scripts/detect-failed-mirrors.sh rename to .claude/skills/gitea-mirror-maintenance/scripts/detect-failed-mirrors.sh diff --git a/CLAUDE.md b/CLAUDE.md index ed177d5..a5d2b9a 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -60,6 +60,21 @@ Every Coolify app created from this repo sets its watch path to `/**`. An app with no watch path deploys on every push to the repository — `traffmonetizer` leaves it unset on purpose, to get restarted that often. +## Service directories hold deploy files only + +Because of that watch path, every file in a service directory redeploys the +service when it changes. A service directory holds only what the deploy reads +or what describes it: `compose.yml`, `README.md`, `.env.example`, +`.gitignore`, and any `Dockerfile`, entrypoint or config file the build or +containers use. + +- **Agent skills** for a service — maintenance scripts, runbooks — go in the + root `.claude/skills//`, never in `/.claude/`. A skill there + also only loads once a session touches that directory. +- **Anything else** that is not deploy input — CI workflows, research notes, + test fixtures — has no default home. Ask the user where it goes before + adding it to a service directory. + ## Workspace services A service someone works *inside* — an editor, a coding agent, anything with a