Agent skill

Gcloud Builds Tag Deploy False Success

by divinevideo in divinevideo/divine-mobile

Fix false-positive Cloud Run deploys where gcloud builds submit --tag silently fails but the follow-up gcloud run services update --image :latest succeeds against a stale image, producing a…

MPL-2.0Auto-check passedDevOps & Cloud

Install Gcloud Builds Tag Deploy False Success

skills CLI
$ npx skills add divinevideo/divine-mobile --skill gcloud-builds-tag-deploy-false-success -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install divinevideo/divine-mobile gcloud-builds-tag-deploy-false-success --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/divinevideo/divine-mobile.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/gcloud-builds-tag-deploy-false-success .claude/skills/gcloud-builds-tag-deploy-false-success && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
gcloud-builds-tag-deploy-false-success
GitHub stars
266
Token cost
~2.3k tokens
SKILL.md length
856 words
Files
1
Skills in repo
103
Repo updated
First seen
Licence
MPL-2.0

At a glance

Fix false-positive Cloud Run deploys where gcloud builds submit --tag silently fails but the follow-up gcloud run services update --image :latest succeeds against a stale image, producing a…

  • Works in 2 steps: The build failure is a single red line… → The :latest tag hides the fact that "the…
  • Code changes verified locally arent visible in production after a deploy that printed revision ..
  • SKILL.md covers Problem, Context / Trigger Conditions, Root cause and Solution, plus 4 more sections
  • Calls gcloud, git and fly

What it does

Gcloud Builds Tag Deploy False Success is an agent skill from divinevideo/divine-mobile. Fix false-positive Cloud Run deploys where gcloud builds submit --tag silently fails but the follow-up gcloud run services update --image :latest succeeds against a stale image, producing a confident "Deploying... Done" message with pre-fix code still live. Use when: (1) gcloud builds submit prints "ERROR: (gcloud.builds.submit) Invalid value for [source]: Dockerfile required when specifying --tag" but the shell scrolls past it, (2) code changes verified locally aren't visible in production after a deploy that…

Its SKILL.md is about 2.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in DevOps & Cloud, covering Containers. It works with Google Cloud, Cloud Run and Docker. The licence is MPL-2.0.

When your agent uses it

  • Code changes verified locally arent visible in production after a deploy that printed revision ..
  • Tasks that involve Containers

Example prompts

  • “Deploying... Done”
  • “but the shell scrolls past it, (2) code changes verified locally aren”
  • “revision ... has been deployed and is serving 100 percent of traffic”
  • “/gcloud-builds-tag-deploy-false-success”

Requirements

  • Docker

Workflow steps

2 steps, taken from the first numbered list in SKILL.md.

  1. The build failure is a single red line among otherwise-green output and it's easy to miss.
  2. The :latest tag hides the fact that "the image didn't actually change" — an immutable

What it can do on your machine

Read from SKILL.md and the folder at commit c3d6f7e. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • gcloud
    • git
    • fly
    • flyctl

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • cloud.google.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Gcloud Builds Tag Deploy False Success loads about 2.3k tokens when it runs. Until then it costs about 199 tokens; SKILL.md has 856 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~199
When it runs · the whole SKILL.md, loaded when a task matches
~2.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from divinevideo/divine-mobile at commit c3d6f7e, republished under its MPL-2.0 licence (© divinevideo). 856 words, ~2,315 tokens.

Download SKILL.mdSave it as .claude/skills/gcloud-builds-tag-deploy-false-success/SKILL.md (or your agent's skills folder).
name
gcloud-builds-tag-deploy-false-success
description
Fix false-positive Cloud Run deploys where `gcloud builds submit --tag` silently fails but the follow-up `gcloud run services update --image :latest` succeeds against a stale image, producing a confident "Deploying... Done" message with pre-fix code still live. Use when: (1) gcloud builds submit prints "ERROR: (gcloud.builds.submit) Invalid value for [source]: Dockerfile required when specifying --tag" but the shell scrolls past it, (2) code changes verified locally aren't visible in production after a deploy that printed "revision ... has been deployed and is serving 100 percent of traffic", (3) Chaining `gcloud builds submit` and `gcloud run services update` in a single copy-paste block, (4) Using the mutable `:latest` tag for Cloud Run deploys.
author
Claude Code
version
1.0.0
date
2026-04-05

gcloud builds submit --tag false-success trap

Problem

A common Cloud Run deploy recipe looks like this:

bash
gcloud builds submit --tag us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:latest
gcloud run services update SERVICE \
  --image us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:latest \
  --region us-central1 --project PROJECT

When the first command fails (most commonly because the current working directory doesn't contain a Dockerfile), its single-line error scrolls off-screen above the second command's verbose progress spinner. The second command then pulls the existing :latest image from Artifact Registry — which is the previous build — and deploys it. You get:

✓ Deploying... Done.
  ✓ Creating Revision...
  ✓ Routing traffic...
Service [...] revision [...] has been deployed and is serving 100 percent of traffic.

A green "SUCCESS" deploy that did not change the running code. The user then spends hours debugging why the fix isn't live, or worse, concludes the fix doesn't work and reverts good code.

Context / Trigger Conditions

  • User reports "I deployed the fix but production behavior is unchanged"
  • Recent shell output contains both:
    • ERROR: (gcloud.builds.submit) Invalid value for [source]: Dockerfile required when specifying --tag
    • revision [...] has been deployed and is serving 100 percent of traffic
  • The gcloud builds submit --tag … was run without a source positional argument AND the working directory does not contain the Dockerfile (common in monorepos where the Dockerfile lives under a subdirectory like cloud-run-upload/, services/api/, etc.)
  • The deploy targets use the mutable :latest tag (or another tag that already exists in the registry)

Root cause

gcloud builds submit --tag IMAGE_TAG needs a source directory. When you omit it, it defaults to the current working directory, and if there's no Dockerfile there (or a cloudbuild.yaml), it exits immediately with exit code 1 — without uploading anything, without creating a build job, without touching Artifact Registry.

Because gcloud run services update --image :latest resolves :latest at deploy time from Artifact Registry, it happily redeploys whatever was there from the previous successful build. Cloud Run's response does not compare the resolved digest to what's already running; it cheerfully creates a new revision pinning the same digest. Output reads "Done" because, from Cloud Run's perspective, everything worked.

Two mistakes compound here:

  1. The build failure is a single red line among otherwise-green output and it's easy to miss.
  2. The :latest tag hides the fact that "the image didn't actually change" — an immutable tag (git SHA, timestamp) would have made the staleness obvious.

Solution

Immediate fix

Rerun the build from the directory containing the Dockerfile, or pass the source as a positional argument:

bash
# Option A: cd into the directory
cd cloud-run-upload
gcloud builds submit --tag us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:latest

# Option B: pass source as positional
gcloud builds submit cloud-run-upload \
  --tag us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:latest

Wait for STATUS: SUCCESS in the output (not just for the prompt to return). Then rerun the gcloud run services update command to pull the new digest.

  1. Use immutable tags. Never deploy :latest to Cloud Run for anything that matters. Tag with git SHA or timestamp so staleness is visible:

    bash
    TAG=$(git rev-parse --short HEAD)
    gcloud builds submit cloud-run-upload \
      --tag us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:${TAG}
    gcloud run services update SERVICE \
      --image us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:${TAG} ...

    If step 1 silently fails, step 2 fails loudly with "image not found" because that tag doesn't exist yet. False-positive converted into a real error.

  2. Chain with && or put the commands in a script with set -e. Copy-pasting two separate commands lets the second run even if the first errored:

    bash
    #!/bin/bash
    set -euo pipefail
    cd "$(dirname "$0")/cloud-run-upload"
    TAG=$(git rev-parse --short HEAD)
    IMAGE=us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:${TAG}
    gcloud builds submit --tag "${IMAGE}"
    gcloud run services update SERVICE --image "${IMAGE}" --region us-central1
  3. Verify the build output contains STATUS: SUCCESS before running the deploy. The last line of a successful gcloud builds submit is STATUS: SUCCESS. If the last line is anything else (especially ERROR:), the build did not happen.

Show full SKILL.md (346 more words)Show less

Verification

After re-running, confirm the deploy actually landed by checking the deployed revision's image digest matches the newly-built one:

bash
# Digest of the tag you just built
gcloud artifacts docker images describe \
  us-central1-docker.pkg.dev/PROJECT/REPO/IMAGE:latest \
  --format='value(image_summary.digest)'

# Digest of the image Cloud Run is currently serving
gcloud run services describe SERVICE --region us-central1 \
  --format='value(spec.template.spec.containers[0].image)'

The second command shows the resolved digest (if :latest was pinned) or the tag. For an end-to-end behavioral check, hit a version endpoint if the service exposes one, or tail logs and confirm new log lines that only the fixed code would emit:

bash
gcloud logging read 'resource.type=cloud_run_revision AND resource.labels.service_name=SERVICE AND textPayload=~"NEW_LOG_LINE_FROM_FIX"' \
  --limit=5 --freshness=5m --format='value(timestamp,textPayload)'

Example

A user runs the following as two separate pasted commands:

$ gcloud builds submit --tag us-central1-docker.pkg.dev/PROJECT/REPO/blossom-upload:latest
ERROR: (gcloud.builds.submit) Invalid value for [source]: Dockerfile required when specifying --tag

$ gcloud run services update divine-blossom-upload \
    --image us-central1-docker.pkg.dev/PROJECT/REPO/blossom-upload:latest \
    --region us-central1 --project PROJECT
✓ Deploying... Done.
  ✓ Creating Revision...
  ✓ Routing traffic...
Done.
Service [divine-blossom-upload] revision [divine-blossom-upload-00008-kvg] has been deployed and is serving 100 percent of traffic.

Revision 00008-kvg is live but runs the pre-fix image. The user tests the fix against production, it still misbehaves, and they escalate: "I deployed and it still doesn't work."

The fix is to rerun gcloud builds submit from the directory containing the Dockerfile (or pass it as a positional), wait for STATUS: SUCCESS, then rerun the gcloud run services update. The next revision will carry the new digest.

Notes

  • This is not specific to Cloud Run. The same shape of bug applies to any deploy pipeline that separates "build image" from "point service at :latest": Kubernetes with imagePullPolicy: Always, ECS with a latest task definition, Fly.io fly deploy after a failed flyctl image push, etc. Whenever the deploy step resolves a mutable tag it inherits the previous image on a build-step failure.
  • gcloud builds submit also accepts --gcs-source-staging-dir and cloudbuild.yaml workflows — the error message changes with those but the principle is identical: verify build success, don't chain commands unconditionally.
  • If you see PERMISSION_DENIED from gcloud builds submit, that's a different failure and also leaves the registry untouched — same false-positive pattern applies.
  • In shells with rtk/tee middleware, a multi-command block can be rerun by index; rerunning just the update command without the build is the exact recipe for recreating this bug.

References

  • gcloud builds submit reference — note that --tag requires a source positional that contains a Dockerfile
  • Cloud Run deploy from source — the gcloud run deploy --source . one-shot avoids this split-command footgun entirely and is worth considering as an alternative workflow
  • Related skill: docker-buildx-stale-rust-binary — different failure mode (layer cache staleness within a successful build) but shares the "deploy looks fine, code is old" symptom

© divinevideo, MPL-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/gcloud-builds-tag-deploy-false-success of divinevideo/divine-mobile.

Open the folder on GitHubat commit c3d6f7e

Compare with similar skills

Gcloud Builds Tag Deploy False Success next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Gcloud Builds Tag Deploy False Success compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Gcloud Builds Tag Deploy False Success this skilldivinevideo/divine-mobile266—~2.3kAutomated safety check: PassMPL-2.0
Devopsnicepkg/auto-company1952 repos~814Automated safety check: PassMIT
GCP Cloud Rundavila7/claude-code-templates33k7 repos~1.7kAutomated safety check: PassMIT
Senior DevOps Toolkitmaslennikov-ig/claude-code-orchestrator-kit2606 repos~1.1kAutomated safety check: NotesCustom licence
Logfire Infrastructurepydantic/skills140—~1.8kAutomated safety check: PassMIT
Docker Containerizationailabs-393/ai-labs-claude-skills455—~2.1kAutomated safety check: NotesMIT

Similar skills

  • Devops

    nicepkg/auto-company

    Deploy to Cloudflare (Workers, R2, D1), Docker, GCP (Cloud Run, GKE), Kubernetes (kubectl, Helm).

    195 GitHub starsUsed in 2 repos~814 tokens
    DevOps & CloudAuto-check passed
  • GCP Cloud Run

    davila7/claude-code-templates

    Specialized skill for building production-ready serverless applications on GCP.

    33k GitHub starsUsed in 7 repos~1.7k tokens
    Backend & APIsAuto-check passed
  • Senior DevOps Toolkit

    maslennikov-ig/claude-code-orchestrator-kit

    Comprehensive DevOps skill for CI/CD, infrastructure automation, containerization, and cloud platforms (AWS, GCP, Azure). Includes pipeline setup…

    260 GitHub starsUsed in 6 repos~1.1k tokens
    DevOps & CloudAuto-check: notes
  • Logfire Infrastructure

    pydantic/skills

    Official

    Monitor hosts, Docker containers, Kubernetes clusters, database/queue/cache servers, and cloud-provider metrics with Pydantic Logfire — no application code required.

    140 GitHub stars~1.8k tokensUpdated 10 days ago
    DevOps & CloudAuto-check passed
  • Docker Containerization

    ailabs-393/ai-labs-claude-skills

    This skill should be used when containerizing applications with Docker, creating Dockerfiles, docker-compose configurations, or deploying containers to various platforms.

    455 GitHub stars~2.1k tokensUpdated 11 mo ago
    DevOps & CloudAuto-check: notes
  • Deploying

    GoogleCloudPlatform/race-condition

    Guides deployment of Race Condition to a GCP project. An agent skill from GoogleCloudPlatform/race-condition.

    234 GitHub stars~3k tokensUpdated 6 days ago
    DevOps & CloudAuto-check passed

More from divinevideo/divine-mobile

All 103 skills in this repo
  • Fix ArgoCD ExternalSecret deployment failing with "namespace X is not permitted in project Y".

    266 GitHub stars~931 tokensUpdated today
    Auto-check passed
  • Art Direct

    divinevideo/divine-mobile

    Art direction for any content — reads text, PDF, Word, HTML, PPT, then proposes 2-3 creative directions with photography style, mood, and visual language.

    266 GitHub stars~4.8k tokensUpdated today
    Auto-check passed
  • Async Await Null Race Condition

    divinevideo/divine-mobile

    Fix "Null check operator used on a null value" errors when an object is set to null during an async await.

    266 GitHub stars~881 tokensUpdated today
    Auto-check passed
  • AWS V4 Signing Custom Headers Gcs

    divinevideo/divine-mobile

    Add custom metadata headers (x-amz-meta-) to AWS v4 signed requests for GCS S3-compatible API.

    266 GitHub stars~1k tokensUpdated today
    Auto-check passed
  • Bash Herestring Newline Secrets

    divinevideo/divine-mobile

    Fix password/secret authentication failures caused by trailing newlines when creating Google Cloud secrets (or similar) with bash here-strings.

    266 GitHub stars~791 tokensUpdated today
    Auto-check passed
  • Fix silent video/media processing failures caused by URL extraction code that filters on file extensions (.mp4, .webm, .webp).

    266 GitHub stars~1.1k tokensUpdated today
    Auto-check passed

Categories

Questions about Gcloud Builds Tag Deploy False Success

What does Gcloud Builds Tag Deploy False Success do?

Fix false-positive Cloud Run deploys where gcloud builds submit --tag silently fails but the follow-up gcloud run services update --image :latest succeeds against a stale image, producing a…. Gcloud Builds Tag Deploy False Success is an agent skill from divinevideo/divine-mobile. Fix false-positive Cloud Run deploys where gcloud builds submit --tag silently fails but the follow-up gcloud run services update --image :latest succeeds against a stale image, producing a confident "Deploying...

When should I use Gcloud Builds Tag Deploy False Success?

Gcloud Builds Tag Deploy False Success fits situations like: code changes verified locally arent visible in production after a deploy that printed revision .; tasks that involve Containers.

How do I install Gcloud Builds Tag Deploy False Success in Claude Code?

Run `npx skills add divinevideo/divine-mobile --skill gcloud-builds-tag-deploy-false-success -a claude-code`. Or copy the skill folder (.agents/skills/gcloud-builds-tag-deploy-false-success in divinevideo/divine-mobile) into .claude/skills/gcloud-builds-tag-deploy-false-success in your project. Claude Code loads it when a task matches its description.

How do I install Gcloud Builds Tag Deploy False Success in Codex?

Run `npx skills add divinevideo/divine-mobile --skill gcloud-builds-tag-deploy-false-success -a codex`. Or copy the skill folder (.agents/skills/gcloud-builds-tag-deploy-false-success in divinevideo/divine-mobile) into .agents/skills/gcloud-builds-tag-deploy-false-success in your project. Codex loads it when a task matches its description.

Can I use Gcloud Builds Tag Deploy False Success in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add divinevideo/divine-mobile --skill gcloud-builds-tag-deploy-false-success -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/gcloud-builds-tag-deploy-false-success, .gemini/skills/gcloud-builds-tag-deploy-false-success, .github/skills/gcloud-builds-tag-deploy-false-success and .opencode/skills/gcloud-builds-tag-deploy-false-success in your project.

What does Gcloud Builds Tag Deploy False Success need to run?

Going by SKILL.md and its folder, Gcloud Builds Tag Deploy False Success needs the command-line tools its instructions call (gcloud, git, fly and flyctl). Our summary lists: Docker.

Does Gcloud Builds Tag Deploy False Success access the network?

SKILL.md names 1 domain. As links in the text: cloud.google.com. This is read from the text; nothing was executed.

Is Gcloud Builds Tag Deploy False Success safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Gcloud Builds Tag Deploy False Success use?

Gcloud Builds Tag Deploy False Success is published under the MPL-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Gcloud Builds Tag Deploy False Success use?

About 2.3k tokens (SKILL.md is roughly 9.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Gcloud Builds Tag Deploy False Success?

Skills that share tags, products or a category with Gcloud Builds Tag Deploy False Success: Devops (nicepkg/auto-company, 195 stars), GCP Cloud Run (davila7/claude-code-templates, 33k stars), Senior DevOps Toolkit (maslennikov-ig/claude-code-orchestrator-kit, 260 stars) and Logfire Infrastructure (pydantic/skills, 140 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Gcloud Builds Tag Deploy False Success?

divinevideo (a GitHub organization) maintains it in divinevideo/divine-mobile, which has 266 GitHub stars. The repository holds 103 skills in this directory. The repository was last updated on October 10, 2026.

Source: divinevideo/divine-mobile on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.