@lifeaitools/rdc-skills 0.13.5 → 0.13.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +9 -3
- package/package.json +1 -1
- package/skills/deploy/SKILL.md +51 -5
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rdc",
|
|
3
|
-
"version": "0.13.
|
|
3
|
+
"version": "0.13.6",
|
|
4
4
|
"description": "RDC typed-agent dispatch skill suite for Claude Code — plan, build, review, overnight unattended builds with work-item tracking and TDD enforcement.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "LIFEAI",
|
|
@@ -297,7 +297,7 @@
|
|
|
297
297
|
"name": "deploy",
|
|
298
298
|
"slash": "rdc:deploy",
|
|
299
299
|
"category": "deploy",
|
|
300
|
-
"usage": "rdc:deploy <slug> [new|diagnose|audit] [--fix]",
|
|
300
|
+
"usage": "rdc:deploy <slug> [new|diagnose|audit|promote] [--fix|--hotfix <sha>]",
|
|
301
301
|
"args": {
|
|
302
302
|
"positional": [
|
|
303
303
|
{
|
|
@@ -310,7 +310,7 @@
|
|
|
310
310
|
"name": "action",
|
|
311
311
|
"required": false,
|
|
312
312
|
"description": "Operation kind",
|
|
313
|
-
"accepts": "new | diagnose | audit | (omit for default deploy)"
|
|
313
|
+
"accepts": "new | diagnose | audit | promote | (omit for default deploy)"
|
|
314
314
|
}
|
|
315
315
|
],
|
|
316
316
|
"flags": [
|
|
@@ -319,6 +319,12 @@
|
|
|
319
319
|
"type": "bool",
|
|
320
320
|
"default": false,
|
|
321
321
|
"description": "Apply remediation during diagnose/audit"
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
"name": "--hotfix",
|
|
325
|
+
"type": "string",
|
|
326
|
+
"default": null,
|
|
327
|
+
"description": "With promote: cherry-pick this specific commit sha to main instead of the app-path develop delta"
|
|
322
328
|
}
|
|
323
329
|
]
|
|
324
330
|
},
|
package/package.json
CHANGED
package/skills/deploy/SKILL.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: rdc:deploy
|
|
3
|
-
description: "Usage `rdc:deploy <slug> [new|diagnose|audit] [--fix]` — Deploy an app to Coolify (production) or PM2 (staging), add a new Coolify app, diagnose a failed deploy, or audit watch paths. Handles DNS, health checks, and post-deploy verification."
|
|
3
|
+
description: "Usage `rdc:deploy <slug> [new|diagnose|audit|promote] [--fix|--hotfix <sha>]` — Deploy an app to Coolify (production) or PM2 (staging), promote a verified dev change to production (one-command cherry-pick → PR → admin-merge → explicit Coolify trigger → verify), add a new Coolify app, diagnose a failed deploy, or audit watch paths. Handles DNS, branch protection, health checks, and post-deploy verification."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
> **⚠️ OUTPUT CONTRACT (READ FIRST):** `guides/output-contract.md`
|
|
@@ -15,10 +15,11 @@ No raw MCP dumps. No UUIDs unless asked.
|
|
|
15
15
|
|
|
16
16
|
> **Sandbox contract:** This skill honors `RDC_TEST=1` per `guides/agent-bootstrap.md` § RDC_TEST Sandbox Contract. Destructive external calls short-circuit under the flag.
|
|
17
17
|
>
|
|
18
|
-
> *Under `$RDC_TEST=1`:* Modes 1 (deploy)
|
|
18
|
+
> *Under `$RDC_TEST=1`:* Modes 1 (deploy), 2 (new), and 5 (promote) are **entirely skipped** — echo `[RDC_TEST] skipping Coolify deploy/create/promote` and mark every `[ ]` line in those checklists as `[~]`. Modes 3 (diagnose) and 4 (audit without `--fix`) are **read-only and run normally**. Mode 4 with `--fix` skips all remediation — echo `[RDC_TEST] skipping audit --fix remediation` and report findings only. Registry SELECTs, Coolify status reads, HTTP gate probes, TLS checks, and DNS lookups are NOT destructive and run normally. Anything that writes (create app, set watch_paths, deploy trigger, **PR/admin-merge to main**, env var write, DNS write, CF cache purge, registry UPDATE/INSERT) is gated.
|
|
19
19
|
|
|
20
20
|
## When to Use
|
|
21
21
|
- Project lead says "deploy", "ship it", "push to production", "update the server"
|
|
22
|
+
- Project lead says "promote", "patch prod", "hotfix production", "push this fix live" — use `rdc:deploy <slug> promote`
|
|
22
23
|
- A new app needs to be registered and deployed for the first time (`rdc:deploy new`)
|
|
23
24
|
- A deployed app is behaving unexpectedly and needs diagnosis (`rdc:deploy diagnose`)
|
|
24
25
|
- Running a compliance/health audit of all deployed apps (`rdc:deploy audit`)
|
|
@@ -27,6 +28,8 @@ No raw MCP dumps. No UUIDs unless asked.
|
|
|
27
28
|
|
|
28
29
|
- `rdc:deploy <slug>` — deploy existing app (latest commit on its watched branch)
|
|
29
30
|
- `rdc:deploy <slug> <build-id>` — deploy specific commit/tag
|
|
31
|
+
- `rdc:deploy <slug> promote` — promote the verified `develop` change for this app to production (Mode 5)
|
|
32
|
+
- `rdc:deploy <slug> promote --hotfix <sha>` — promote a specific commit (cherry-pick just that sha to `main`)
|
|
30
33
|
- `rdc:deploy new <slug>` — create a new Coolify app from registry
|
|
31
34
|
- `rdc:deploy diagnose <slug>` — debug why an app is broken
|
|
32
35
|
- `rdc:deploy audit` — fleet-wide scan for missed failures
|
|
@@ -138,6 +141,48 @@ Severity rules:
|
|
|
138
141
|
|
|
139
142
|
`--fix` auto-remediates only: missing watch_paths, registry row updates, CF cache purges. Never touches env vars, DNS, or container config without explicit confirmation.
|
|
140
143
|
|
|
144
|
+
### Mode 5 — promote <slug> [--hotfix <sha>]
|
|
145
|
+
|
|
146
|
+
Promote a **verified `develop` change** for one app to production. This is the sanctioned production-patch fast path — one command instead of fighting branch protection, the main-push hook, and a flaky Coolify webhook by hand.
|
|
147
|
+
|
|
148
|
+
**Authorization:** production promote requires explicit user go-ahead ("promote", "patch prod", "push live", "go"). A dev deploy does NOT. If the user has not given it for THIS promote, stop and ask first.
|
|
149
|
+
|
|
150
|
+
```
|
|
151
|
+
rdc:deploy promote: <slug> → <prod-domain>
|
|
152
|
+
[ ] Registry lookup: PROD row (uuid, prod branch=main, watch_paths, url)
|
|
153
|
+
[ ] PUBLISH.md status gate: status=active AND prod in environments (block if not)
|
|
154
|
+
[ ] Scope resolved: --hotfix <sha> → that commit; else the app-path commits on develop not on main
|
|
155
|
+
[ ] Scope guard: promote ONLY this app's paths. NEVER merge develop→main wholesale (drags unrelated WIP to prod)
|
|
156
|
+
[ ] Clean worktree off origin/main (never switch the dirty working tree)
|
|
157
|
+
[ ] Apply change: cherry-pick <sha> (or `git checkout <develop-sha> -- <app-paths>`); confirm diff = expected files only
|
|
158
|
+
[ ] Mandatory pre-promote code-review (pr-review-toolkit:code-reviewer on the promote diff). Block on critical/high.
|
|
159
|
+
[ ] Commit on promote branch; push branch (NOT main directly — the main-push hook blocks raw main pushes)
|
|
160
|
+
[ ] Open PR base=main; merge with admin override (`gh pr merge --squash --admin --delete-branch`) — branch protection needs --admin
|
|
161
|
+
[ ] EXPLICITLY trigger Coolify deploy — NEVER rely on the GitHub→Coolify webhook (it silently no-ops on some merges even with auto-deploy ON)
|
|
162
|
+
[ ] Deployment reached "finished" state (poll coolify_events / deployment status)
|
|
163
|
+
[ ] Gate: HTTP 200 on prod domain
|
|
164
|
+
[ ] Gate: content-level check — assert the actual changed string is live (200 alone is NOT proof; origin may serve stale)
|
|
165
|
+
[ ] Gate: TLS valid
|
|
166
|
+
[ ] Cloudflare cache purged (if proxied)
|
|
167
|
+
[ ] deployment_registry updated (last_deploy_at, last_deploy_commit, status)
|
|
168
|
+
✅ rdc:deploy promote: <slug> live in prod — <changed-string> verified
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
**The explicit Coolify trigger (the whole point — do not skip):**
|
|
172
|
+
```bash
|
|
173
|
+
_COOLIFY=$(curl -s http://127.0.0.1:52437/v/coolify-api)
|
|
174
|
+
# Correct endpoint is GET /api/v1/deploy?uuid= — NOT POST /applications/<uuid>/deploy (that 404s)
|
|
175
|
+
curl -s -H "Authorization: Bearer $_COOLIFY" \
|
|
176
|
+
"$DEPLOY_API_BASE/api/v1/deploy?uuid=<PROD_UUID>&force=true"
|
|
177
|
+
# → {"deployments":[{"deployment_uuid":"...","message":"...deployment queued."}]}
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
**Why each guard exists (lessons from 2026-06-05 EF Hooper promote):**
|
|
181
|
+
- `main` branch protection rejects PR merge without `--admin`; a raw `git push …:main` is blocked by the main-push hook → must go branch → PR → admin-merge.
|
|
182
|
+
- Coolify auto-deploy was **ON** for the app yet the merge did **not** auto-deploy — a webhook-delivery flake. A promote must ALWAYS trigger the deploy explicitly and verify; never hope the webhook fired.
|
|
183
|
+
- `develop` was 87 commits ahead of `main` (unrelated apps' WIP). Promoting must be surgical (this app's paths / one sha), never a develop→main merge.
|
|
184
|
+
- HTTP 200 was returned by the stale origin the whole time — only a content-level assertion (`curl … | grep '<new string>'`) proves the promote landed.
|
|
185
|
+
|
|
141
186
|
## PUBLISH.md Integration
|
|
142
187
|
|
|
143
188
|
Every deploy reads `PUBLISH.md` from the app's source root to derive `watch_paths` and to register surfaces in Studio `artifact_registry`.
|
|
@@ -225,9 +270,10 @@ curl -s -H "Authorization: Bearer $_COOLIFY" \
|
|
|
225
270
|
curl -s -H "Authorization: Bearer $_COOLIFY" \
|
|
226
271
|
"$DEPLOY_API_BASE/api/v1/applications/<uuid>"
|
|
227
272
|
|
|
228
|
-
# Deploy (trigger)
|
|
229
|
-
|
|
230
|
-
|
|
273
|
+
# Deploy (trigger) — correct endpoint is GET /api/v1/deploy?uuid=
|
|
274
|
+
# (POST /applications/<uuid>/deploy returns {"message":"Not found."})
|
|
275
|
+
curl -s -H "Authorization: Bearer $_COOLIFY" \
|
|
276
|
+
"$DEPLOY_API_BASE/api/v1/deploy?uuid=<uuid>&force=true"
|
|
231
277
|
|
|
232
278
|
# Get deployment logs
|
|
233
279
|
curl -s -H "Authorization: Bearer $_COOLIFY" \
|