Advanced (更新: 2026/7/19)

制作公司用 Cloud Build CI/CD 减少客户落地页发布事故

面向制作公司的 Cloud Build、审批门、服务账号和落地页发布前检查流程。

制作公司用 Cloud Build CI/CD 减少客户落地页发布事故

制作公司发布客户落地页时,最危险的常常不是代码,而是最后一次确认。价格表改了,但旧活动图回来了。测试 formId 上了生产。广告标签被删掉。另一个客户的环境变量被用于构建。

本文把 Cloud Build 当作制作公司的发布检查流程。Claude Code 起草检查表、差分表和 cloudbuild.yaml,人来确认客户承诺、价格、法务文案、广告标签和发布时间。

本文要点

  • Check client name, URL, form ID, tracking tags, price, legal copy, approver, and rollback before deploy.

  • Cloud Build gives triggers, approvals, repository connections, service accounts, and build logs.

  • Claude Code drafts release tables, diff summaries, cloudbuild.yaml changes, and rollback notes.

  • Humans approve client promises, price, legal copy, tracking, and production timing.

  • Send serious readers to training because release workflows depend on each agency.

制作公司常见发布事故

发布流程要先列出客户名、公开 URL、确认 URL、分支、formId、广告标签、价格表、法务文案、OGP 图、审批者、build id 和回滚命令。Cloud Build trigger 可以由仓库事件启动构建,approval gate 可以让构建等待授权人员审批。用户指定服务账号可以缩小每条发布路径的权限。

Official references: Cloud Build, triggers, approval gates, repositories, user-specified service accounts, and default service account guidance.

流程:发布前拦住落地页错误

发布流程要先列出客户名、公开 URL、确认 URL、分支、formId、广告标签、价格表、法务文案、OGP 图、审批者、build id 和回滚命令。Cloud Build trigger 可以由仓库事件启动构建,approval gate 可以让构建等待授权人员审批。用户指定服务账号可以缩小每条发布路径的权限。

| Area | Draft from Claude Code | Human review |

| --- | --- | --- |

| cloudbuild.yaml | build, test, deploy, rollback | production approver |

| Diff | changed files, price, CTA, tags | client-approved content |

| Env names | required keys, staging/prod difference | no secret values pasted |

| Form | action, formId, thanks URL | production destination |

| Build log | build id, commit, approver, URL | rollback is recorded |

Claude Code 负责什么,人负责什么

发布流程要先列出客户名、公开 URL、确认 URL、分支、formId、广告标签、价格表、法务文案、OGP 图、审批者、build id 和回滚命令。Cloud Build trigger 可以由仓库事件启动构建,approval gate 可以让构建等待授权人员审批。用户指定服务账号可以缩小每条发布路径的权限。

3 个 Use case

Use case 1: Release checklist per client LP

  • Input: cloudbuild.yaml, package.json, LP diff, preview URL, client approval memo, form settings.

  • Output: checklist for price, CTA, form ID, tracking tag, OGP, thanks URL, approver.

  • Human review: confirm client-approved copy, release time, and production contact destination.

Use case 2: Add an approval gate

  • Input: trigger settings, target branch, release target, approver, emergency rule.

  • Output: approval conditions, approver, build id, commit, release URL, rejection steps.

  • Human review: decide whether this client needs approval and whether release timing matches ads.

Use case 3: Split service accounts by client path

  • Input: Cloud Build service account, Secret references, host target, client project, public URL.

  • Output: client, service account, readable secrets, deploy target, broad permission candidates.

  • Human review: confirm client A builds cannot read client B secrets, and retired users are gone.

可复制提示词


Review a web agency Cloud Build CI/CD workflow. Goal: reduce client landing page release incidents. Build a release checklist for client name, URL, form ID, tracking tags, price table, approver, and rollback. Separate what Claude Code can inspect, what a human must approve, and what requires client approval. Do not run change commands. Main CTA: /training/.

可运行检查代码


const releases = [{ client: 'Client B', url: 'https://example.net/campaign', formId: 'stg-contact', approver: '', rollback: '' }];

const findings = releases.flatMap((r) => {

  const issues = [];

  if (!r.url.startsWith('https://')) issues.push('URL is not HTTPS');

  if (!r.formId || /stg|test|dev/i.test(r.formId)) issues.push('form ID looks like staging');

  if (!r.approver) issues.push('approver is missing');

  if (!r.rollback) issues.push('rollback is missing');

  return issues.map((issue) => ({ client: r.client, issue }));

});

console.table(findings);

if (findings.length) process.exitCode = 1;

Pitfall: CI/CD 让发布更快,也让事故更大

发布流程要先列出客户名、公开 URL、确认 URL、分支、formId、广告标签、价格表、法务文案、OGP 图、审批者、build id 和回滚命令。Cloud Build trigger 可以由仓库事件启动构建,approval gate 可以让构建等待授权人员审批。用户指定服务账号可以缩小每条发布路径的权限。

Cause: automation makes the release path fast before the human review path is clear. Fix: let machines check build, links, env names, and form ID format; keep price, legal copy, client approval, and ad timing as human approval steps.

FAQ

Q. Is Cloud Build too heavy for an agency? A. Use it first for high-frequency LPs, forms, and ad-linked releases.

Q. Why not GitHub Actions? A. GitHub Actions can work. Cloud Build is convenient when secrets, hosting, Cloud Run, Cloud Storage, Artifact Registry, and logs are already in Google Cloud.

Q. Can Claude Code deploy directly? A. Start with tables and diffs. Production deploy should wait for human approval.

咨询入口

ClaudeCodeLab training can help design Cloud Build triggers, approval gates, client-specific service accounts, and rollback notes for an agency release workflow.

实际检查结果

This article checks frontmatter, official links, three use cases, input-output-human review labels, code fences, and the /training/ CTA. The JavaScript sample detects staging form IDs, missing approvers, and missing rollback steps.

#claude-code #制作公司 #Cloud Build #CI/CD #发布流程
免费

免费 PDF: Claude Code 速查表

输入邮箱即可获取一页 PDF,整理常用命令、审查习惯和安全工作流。

我们会妥善保护你的信息,不发送垃圾邮件。

让 Claude Code 真正进入可验证的工作流

先用免费 PDF 固定基础,再用 Gumroad 教材复用工作流;如果涉及团队导入、权限或收入路径,可以直接咨询。

Masa

关于作者

Masa

专注 Claude Code 实务流程、团队导入和内容转化的工程师。