agentleFS
RoboFinSystemsRoboFinSystems/robosystems/.claude/skills/deploy/SKILL.md

deploy

Skill31 starsChanged 14 days agoApache-2.0View on GitHub

Monitor a deployment run: pinpoint why it failed, drive a re-run to green, and verify health. Deploys run through GitHub Actions; this watches and diagnoses them. Started only by the user, because a re-run repeats a deploy's side effects.

169 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use Code Review & Quality, Incremental Implementation and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • fdhhhdjdSkill

    Code Review & Quality

    Five-axis code review for comprehensive quality assessment

    Also in 3 projects that use this

  • fdhhhdjdSkill

    Incremental Implementation

    Build features in thin vertical slices with continuous verification

    Also in 3 projects that use this

  • ww-w-aiSkill

    qa-phase

    Run QA tests at various levels (L1-L5) for features under PDCA management. Integrates with MCP tools to execute structured test plans.

    Also in 3 projects that use this

  • ww-w-aiSkill

    desktop-app

    Desktop application development guide for Electron, Tauri, and native apps. Covers cross-platform desktop development for macOS, Windows, and Linux. Triggers: desktop app, Electron, Tauri, mac app, windows app, native app, 데스크톱 앱, 일렉트론, 타우리, デスクトップアプリ, Electron, 桌面应用, 桌面程序, aplicacion de escritorio, application bureau, Desktop-App Do NOT use for: mobile apps (use $mobile-app), web apps (use $dynamic or $starter).

    Also in 4 projects that use this

  • +1 more from fdhhhdjd
  • +7 more from ww-w-ai

The file

Files
SKILL.md

Monitor a deployment run — pinpoint why it failed, drive it to green on a re-run, and verify health. Deploys go through GitHub Actions (workflow_dispatch); this skill is about watching and diagnosing them, not replacing the pipeline. Pairs with the deployment-monitoring runbook in the private design vault's runbooks/ for account-specific stack names and failure classes — read it alongside this file.

When this runs

Most deploys (~95%) go green untouched and need no attention. The real use case is the other 5%: a deploy failed, and you're re-running it and want eyes on this one. Optimize for that — get to the failing job fast, classify it, fix the cause, re-trigger, and confirm the app is healthy afterward.

Scope & guardrails

  • gh reads are free; the deploy trigger is not. Reading runs, jobs, and logs (gh run list/view/watch) needs no confirmation. Triggering or re-triggering a deploy (gh workflow run, just deploy) is an outward-facing action — confirm the target (env + ref) with the user first, and default to watching a run they already started.
  • AWS is read-only here. describe-* / list-* only. CloudFormation changes and stack deletions are the user's to run — never create-stack/update-stack/delete-stack directly.
  • Never deploy the default branch to prod. Production should ride a version tag / release branch produced by the release workflow. Verify the ref before triggering rather than assuming the pipeline will reject a bad one, and when reviewing history (gh run list --json headBranch,displayTitle), flag any past prod run that rode a branch rather than a tag.
  • just deploy defaults are dangerous if you're not explicit. The recipe defaults to the prod environment and the current branch. Always pass both arguments.
  • Output can be sensitive. Failure logs name internal hostnames, stack names, and resource IDs. Don't paste raw infra detail into anything public; summarize.

1. Find the run

Identify env (staging | prod) and which run you're looking at. If the user didn't say, ask or infer from context.

gh run list --workflow=staging.yml --limit 5     # or prod.yml
gh run view <run-id>                              # job-level status
gh run watch <run-id>                             # live, if it's in flight

The deploy is one large workflow of dependent jobs: build/test gate everything, then the infrastructure stacks, then the app services and the graph-tier refresh run in parallel off their own upstreams — the refresh does not wait on the app services. A single failed job fails the run. Find the first failed job; downstream failures are usually just the cascade.

That parallelism matters when reading a failure: a failed graph refresh does not mean the app services finished, and a green app service does not mean the refresh did.

2. Pinpoint the failure

gh run view <run-id> --log-failed      # logs for only the failed step(s)

Classify by which stage broke — each has a different fix and blast radius:

  • Config gate (first job, before build) — the run aborts because the target environment isn't enabled for that component. Nothing was built and nothing was deployed; the fix is a GitHub variable, not code. This fails earlier than test/build, so check it first when a run dies almost immediately.
  • Test / build — code problem, no infra touched. Safe to fix and re-run; nothing was deployed.
  • Infrastructure stack (CloudFormation) — a stack update failed. The dangerous class: a stack left in a rollback state usually can't be updated again until it's resolved, so a naive re-run fails identically. See the runbook.
  • App service (API / orchestrator) — the container-based services roll out on the new image tag; a failure here is often a bad image, a failed health check, or a migration abort (see /migrate).
  • Post-deploy refresh — the graph tier cycles its instances separately from the app services; this can wait on in-flight work or fail on health, without the app deploy being bad.

3. Remediate, then re-deploy

Fix the root cause first (code fix + merge, a stuck stack resolved, a config/variable corrected). Then, with the user's confirmation, re-trigger:

just deploy staging          # or: just deploy prod <tag>
# equivalently: gh workflow run staging.yml --ref <branch-or-tag>

Note the deploy workflow is serialized (a concurrency group with cancel-in-progress: false) — a new run queues behind any in-flight one rather than cancelling it. Both environments share the same group, so a staging deploy will also queue behind an in-flight prod deploy. Don't fire a second deploy expecting it to preempt the first, and check for a queued run before concluding a deploy "isn't starting".

4. Verify health

A green workflow means the pipeline finished, not that the app is serving. Confirm the API process is answering:

curl -sf https://<api-host>/v1/status && echo OK      # public API over HTTPS
# if the API is in internal mode: tunnel first, then curl http://localhost:18000/v1/status

/v1/status is a liveness probe — it returns healthy whenever the process is up; it does not check the database, cache, or graph. A 200 means "the API is serving HTTP," not "the stack is healthy." Confirm the rest yourself: the app service (running vs desired count), recent errors in its log group, and — if the deploy carried a migration — the orchestrator boot logs (/migrate).

Output

A short status: what failed and at which stage, the root cause, what you changed, the re-run link, and the post-deploy health result. If nothing failed, say so — don't manufacture work.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.