CI/CD

Babysit Cloudflare deployment

On every Cloudflare deploy, check post-deploy health and open an incident with a rollback recommendation when degraded.

Triggered when a Cloudflare deploy lands. The agent compares post-deploy error rate, latency, and log patterns against a 2-hour baseline using Cloudflare telemetry plus any connected APM (Datadog, Honeycomb, Axiom, Sentry). When the deploy is degraded, it opens a workspace incident with the failing metric, the deploy ID, and a recommended rollback strategy so a human can decide. Healthy deploys produce a brief HEALTHY report and nothing else. No automatic rollback — use this when you want the agent to surface bad deploys without changing infrastructure.

Install

Create this automation from the CLI, or pick it in the console under Automations → New → From template.

Terminal
polylane automation from-template babysit-cloudflare-deployment

Trigger

The event that starts this automation.

Cloudflare Deploy10min delay

Fires when a Cloudflare deploy lands (Workers script update, Pages deployment, container rollout, or versioned Worker promotion).

Compatible providers

1

Integrations this automation investigates and uses tools from. Connect them to unlock the full workflow.

Cloudflare

Skills

3

These skills are installed automatically when you create this automation.

/deployment-validation
/investigate-errors
/investigate-latency

Actions

1

Platform-executed side effects the agent can request. These are applied when you create this automation.

Open Incident smart

Agent instructions

The prompt the agent follows on each execution. Customize it to fit your team's playbook.

## Role You are Cloudflare Deploy Investigator. Validate the deploy that just landed; if degraded, open an incident with evidence and a rollback recommendation. You do not roll back yourself. ## Sources 1. Trigger payload: account, resource type, resource ID, deploy ID, environment, actor. 2. Cloudflare telemetry: error rate, latency, request volume. 3. Connected APM (Datadog / Honeycomb / Axiom / Sentry). ## Workflow 1. Pull error rate and latency over the post-deploy window with the prior 2 hours as baseline. 2. If degraded (>10% error or >15% latency or new error patterns), open an incident via `openIssue` with severity 'high', a clear summary, and a body containing the evidence and a recommended rollback strategy. 3. If healthy, post a brief HEALTHY report and stop. ## Output Incident body should include: deploy ID, resource, evidence (metrics + queries + time window), recommended rollback strategy. ## Operating rules - Cite metrics with provider, query, and time range. - Do not open an incident for healthy deploys. - Severity 'high' for elevated error rate, 'critical' for full outage signals, 'medium' for latency-only degradation.

Parallel passes

Each execution runs multiple analysis passes with different perspectives, then aggregates the results.2 passes

How it works

When a cloudflare deploy event occurs, an agent runs the instructions above, investigating with your connected Cloudflare tools, and sends results to your configured destinations.

Destinations

When you create this automation your email is added as a destination, so every run lands in your inbox. Add chat or webhook destinations afterward.

Related templates