google-agents-cli-scaffold
Project scaffolding, deployment configuration, and CI/CD setup for Google ADK agents.
google-cloud-build-expert
Expert knowledge of Google Cloud Build CI/CD pipelines including cloudbuild.yaml syntax, build steps, builders, substitution variables, triggers, secrets, artifact handling, and deployment to Cloud Run. Use when working with Cloud Build configurations, troubleshooting build pipelines, or deployin...
Full skill instructions
This skill provides comprehensive expert knowledge of Google Cloud Build for CI/CD pipeline configuration, Docker image building, and automated deployment to Google Cloud services.
Standard cloudbuild.yaml structure:
steps:
- name: 'builder-image'
args: ['arg1', 'arg2']
env: ['ENV_VAR=value']
dir: 'subdirectory'
id: 'step-id'
waitFor: ['previous-step-id']
timeout: '300s'
substitutions:
_CUSTOM_VAR: 'value'
options:
machineType: 'N1_HIGHCPU_8'
substitutionOption: 'ALLOW_LOOSE'
logging: 'CLOUD_LOGGING_ONLY'
logStreamingOption: 'STREAM_ON'
timeout: '1200s'
Docker Builder:
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/myimage:$COMMIT_SHA', '.']
gcloud SDK Builder:
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: 'gcloud'
args: ['run', 'deploy', 'myservice', '--image', 'gcr.io/$PROJECT_ID/myimage:$COMMIT_SHA']
npm Builder:
- name: 'gcr.io/cloud-builders/npm'
args: ['install']
git Builder:
- name: 'gcr.io/cloud-builders/git'
args: ['clone', 'https://github.com/user/repo']
Sequential execution:
steps:
- name: 'gcr.io/cloud-builders/npm'
id: 'install'
args: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'test'
args: ['test']
waitFor: ['install']
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'image', '.']
waitFor: ['test']
Parallel execution:
steps:
- name: 'gcr.io/cloud-builders/npm'
id: 'install'
args: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'lint'
args: ['run', 'lint']
waitFor: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'test'
args: ['test']
waitFor: ['install']
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '.']
waitFor: ['lint', 'test'] # Waits for both
Automatic variables provided by Cloud Build:
$PROJECT_ID - Google Cloud project ID$PROJECT_NUMBER - Google Cloud project number$BUILD_ID - Unique build identifier$COMMIT_SHA - Git commit SHA (for repo triggers)$SHORT_SHA - Short (7-char) commit SHA$BRANCH_NAME - Git branch name$TAG_NAME - Git tag name$REVISION_ID - Source revision ID$REPO_NAME - Repository name$TRIGGER_NAME - Trigger name that initiated buildDefine in cloudbuild.yaml:
substitutions:
_SERVICE_NAME: 'my-app'
_REGION: 'us-central1'
_IMAGE_TAG: 'v1.0.0'
_ENVIRONMENT: 'production'
Reference in steps:
steps:
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/${_SERVICE_NAME}:${_IMAGE_TAG}', '.']
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- '${_SERVICE_NAME}'
- '--image'
- 'gcr.io/$PROJECT_ID/${_SERVICE_NAME}:${_IMAGE_TAG}'
- '--region'
- '${_REGION}'
Naming conventions:
_CUSTOM_VAR$PROJECT_ID_SERVICE_NAME not _SVCoptions:
substitutionOption: 'ALLOW_LOOSE' # Allow undefined substitutions
# OR
substitutionOption: 'MUST_MATCH' # Fail if substitution undefined
steps:
# Build the container image
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA', '.']
# Push to Container Registry
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA']
steps:
- name: 'gcr.io/cloud-builders/docker'
args:
- 'build'
- '-t'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '-t'
- 'gcr.io/$PROJECT_ID/myapp:latest'
- '.'
- name: 'gcr.io/cloud-builders/docker'
args: ['push', '--all-tags', 'gcr.io/$PROJECT_ID/myapp']
steps:
- name: 'gcr.io/cloud-builders/docker'
args:
- 'build'
- '-t'
- 'us-central1-docker.pkg.dev/$PROJECT_ID/my-repo/myapp:$COMMIT_SHA'
- '.'
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'us-central1-docker.pkg.dev/$PROJECT_ID/my-repo/myapp:$COMMIT_SHA']
steps:
- name: 'gcr.io/cloud-builders/docker'
args:
- 'build'
- '--build-arg'
- 'NODE_VERSION=18'
- '--build-arg'
- 'BUILD_ENV=production'
- '-t'
- 'gcr.io/$PROJECT_ID/myapp'
- '.'
steps:
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA', '.']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA']
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- 'myapp'
- '--image'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '--region'
- 'us-central1'
- '--platform'
- 'managed'
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- 'myapp'
- '--image'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '--region'
- 'us-central1'
- '--platform'
- 'managed'
- '--set-env-vars'
- 'NODE_ENV=production,LOG_LEVEL=info'
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- 'myapp'
- '--image'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '--region'
- 'us-central1'
- '--set-secrets'
- 'API_KEY=my-secret:latest'
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- 'myapp'
- '--image'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '--region'
- 'us-central1'
- '--platform'
- 'managed'
- '--allow-unauthenticated'
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- 'myapp'
- '--image'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '--region'
- 'us-central1'
- '--memory'
- '512Mi'
- '--cpu'
- '1'
- '--max-instances'
- '10'
- '--concurrency'
- '80'
steps:
- name: 'gcr.io/cloud-builders/npm'
env:
- 'NODE_ENV=production'
- 'API_ENDPOINT=https://api.example.com'
args: ['run', 'build']
availableSecrets:
secretManager:
- versionName: projects/$PROJECT_ID/secrets/api-key/versions/latest
env: 'API_KEY'
- versionName: projects/$PROJECT_ID/secrets/db-password/versions/latest
env: 'DB_PASSWORD'
steps:
- name: 'gcr.io/cloud-builders/npm'
secretEnv: ['API_KEY', 'DB_PASSWORD']
args: ['run', 'deploy']
secrets:
- kmsKeyName: 'projects/PROJECT_ID/locations/global/keyRings/KEYRING/cryptoKeys/KEY'
secretEnv:
API_KEY: 'CiQAVz...' # Base64 encrypted value
steps:
- name: 'gcr.io/cloud-builders/npm'
secretEnv: ['API_KEY']
args: ['run', 'deploy']
Node.js npm cache:
steps:
- name: 'gcr.io/cloud-builders/npm'
args: ['ci', '--cache', '.npm']
env:
- 'npm_config_cache=/workspace/.npm'
Docker layer caching:
options:
machineType: 'N1_HIGHCPU_8'
diskSizeGb: 100
steps:
- name: 'gcr.io/cloud-builders/docker'
args:
- 'build'
- '--cache-from'
- 'gcr.io/$PROJECT_ID/myapp:latest'
- '-t'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '.'
steps:
- name: 'gcr.io/cloud-builders/npm'
id: 'install'
args: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'lint'
args: ['run', 'lint']
waitFor: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'test'
args: ['test']
waitFor: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'build'
args: ['run', 'build']
waitFor: ['lint', 'test']
steps:
- name: 'gcr.io/cloud-builders/npm'
args: ['install']
timeout: '300s' # 5 minutes
- name: 'gcr.io/cloud-builders/npm'
args: ['test']
timeout: '600s' # 10 minutes
timeout: '1200s' # 20 minutes for entire build
steps:
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '.']
Default timeout: 10 minutes (600s) Maximum timeout: 24 hours (86400s)
options:
logging: CLOUD_LOGGING_ONLY
logStreamingOption: STREAM_ON
options:
logging: GCS_ONLY
logsBucket: 'gs://my-build-logs'
options:
logging: CLOUD_LOGGING_ONLY
logStreamingOption: STREAM_ON
Trigger on push to main branch:
# In trigger configuration (not cloudbuild.yaml)
name: deploy-main
description: Deploy on push to main
filename: cloudbuild.yaml
github:
owner: myorg
name: myrepo
push:
branch: ^main$
Trigger on pull request:
github:
owner: myorg
name: myrepo
pullRequest:
branch: ^main$
commentControl: COMMENTS_ENABLED
Trigger on tag:
github:
owner: myorg
name: myrepo
tag: ^v[0-9]+\.[0-9]+\.[0-9]+$
steps:
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '.']
# Only deploy on main branch
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: bash
args:
- '-c'
- |
if [ "$BRANCH_NAME" = "main" ]; then
gcloud run deploy myapp --image gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA
fi
serviceAccount: 'projects/PROJECT_ID/serviceAccounts/my-build-sa@PROJECT_ID.iam.gserviceaccount.com'
steps:
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
args: ['run', 'deploy', 'myapp']
For Cloud Build Service Account:
roles/run.admin - Deploy to Cloud Runroles/iam.serviceAccountUser - Act as service accountroles/storage.admin - Push to Container Registry/Artifact Registryroles/secretmanager.secretAccessor - Access Secret Managersteps:
# Install dependencies
- name: 'gcr.io/cloud-builders/npm'
args: ['ci', '--only=production']
# Run tests
- name: 'gcr.io/cloud-builders/npm'
args: ['test']
env:
- 'NODE_ENV=test'
# Build Docker image
- name: 'gcr.io/cloud-builders/docker'
args:
- 'build'
- '-t'
- 'gcr.io/$PROJECT_ID/${_SERVICE_NAME}:$COMMIT_SHA'
- '-t'
- 'gcr.io/$PROJECT_ID/${_SERVICE_NAME}:latest'
- '.'
# Push to Container Registry
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/${_SERVICE_NAME}:$COMMIT_SHA']
# Deploy to Cloud Run
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- '${_SERVICE_NAME}'
- '--image'
- 'gcr.io/$PROJECT_ID/${_SERVICE_NAME}:$COMMIT_SHA'
- '--region'
- '${_REGION}'
- '--platform'
- 'managed'
- '--allow-unauthenticated'
- '--set-env-vars'
- 'NODE_ENV=production'
substitutions:
_SERVICE_NAME: 'my-node-app'
_REGION: 'us-central1'
options:
machineType: 'N1_HIGHCPU_8'
logging: CLOUD_LOGGING_ONLY
timeout: '1200s'
# Good
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA', '.']
# Avoid (less reproducible)
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/myapp:latest', '.']
steps:
# Run quick checks first
- name: 'gcr.io/cloud-builders/npm'
args: ['run', 'lint']
- name: 'gcr.io/cloud-builders/npm'
args: ['test']
# Expensive operations last
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '.']
waitFor: ['lint', 'test']
# Good - easy to modify
substitutions:
_SERVICE_NAME: 'my-app'
_REGION: 'us-central1'
# Avoid - hardcoded values throughout
steps:
- name: 'gcr.io/cloud-builders/npm'
args: ['install']
timeout: '300s' # Prevent hanging builds
options:
logging: CLOUD_LOGGING_ONLY
logStreamingOption: STREAM_ON # See logs in real-time
steps:
- name: 'gcr.io/cloud-builders/docker'
args:
- 'build'
- '--cache-from'
- 'gcr.io/$PROJECT_ID/myapp:latest'
- '-t'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '.'
steps:
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA', '.']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA']
# Deploy to staging
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- 'myapp-staging'
- '--image'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '--region'
- 'us-central1'
# Deploy to production (manual approval required via trigger config)
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args:
- 'run'
- 'deploy'
- 'myapp-production'
- '--image'
- 'gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA'
- '--region'
- 'us-central1'
steps:
- name: 'gcr.io/cloud-builders/gcloud'
entrypoint: 'bash'
args:
- '-c'
- |
echo "Starting deployment..."
gcloud run deploy myapp \
--image gcr.io/$PROJECT_ID/myapp:$COMMIT_SHA \
--region us-central1
echo "Deployment complete!"
steps:
- name: 'gcr.io/cloud-builders/npm'
id: 'install'
args: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'lint'
args: ['run', 'lint']
waitFor: ['install']
- name: 'gcr.io/cloud-builders/npm'
id: 'test'
args: ['test']
waitFor: ['install']
- name: 'gcr.io/cloud-builders/docker'
id: 'build'
args: ['build', '-t', 'gcr.io/$PROJECT_ID/myapp', '.']
waitFor: ['lint', 'test'] # Only build if tests pass
- name: 'gcr.io/cloud-builders/docker'
id: 'push'
args: ['push', 'gcr.io/$PROJECT_ID/myapp']
waitFor: ['build']
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: gcloud
args: ['run', 'deploy', 'myapp', '--image', 'gcr.io/$PROJECT_ID/myapp']
waitFor: ['push']
Error: "failed to find one or more images"
waitForError: "timeout exceeded"
Error: "permission denied"
Error: "substitution not found"
substitutions section or use ALLOW_LOOSEView build logs:
gcloud builds list
gcloud builds log BUILD_ID
View build details:
gcloud builds describe BUILD_ID
Test locally (Cloud Build Local):
cloud-build-local --config=cloudbuild.yaml --dryrun=false .
Project scaffolding, deployment configuration, and CI/CD setup for Google ADK agents.
Set up tracing, logging, and monitoring for deployed ADK agents across Cloud Trace, BigQuery, and third-party platforms.
Enterprise Azure infrastructure architect generating Bicep or Terraform from workload descriptions.
Plan and configure production-ready Azure Kubernetes Service clusters with Day-0 and Day-1 best practices.
Raw mechanical interfaces fusing Swiss typographic print with military terminal aesthetics. Rigid grids, extreme type scale contrast, utilitarian color, analog degradation effects. For data-heavy dashboards, portfolios, or editorial sites that need to feel like declassified blueprints.
Web search, scraping, extraction, crawling, and monitoring via ScrapeGraph AI CLI.
Skill for working with Firebase Hosting (Classic). Use this when you want to deploy static web apps, Single Page Apps (SPAs), or simple microservices. Do NOT use for Firebase App Hosting.
Deploy and manage web apps with Firebase App Hosting. Use this skill when deploying Next.js/Angular apps with backends.
Deploy applications and websites to Vercel. Use when the user requests deployment actions like "deploy my app", "deploy and give me the link", "push this live", or "create a preview deployment".
Build SEO-optimized pages at scale using templates, data, and proven playbook patterns.
Design and build isolated, reusable Convex backend components with clear boundaries and app-facing wrappers.
Deploy and manage projects on Vercel using token-based authentication. Use when working with Vercel CLI using access tokens rather than interactive login — e.g. "deploy to vercel", "set up vercel", "add environment variables to vercel".
Opus.ai: Revolutionize Your Web Experience
Build a no-code AI app in minutes.
An IDE for code migration from legacy to modern frameworks through coding agents.
Automate CGI animation in live-action scenes
Branded artistic QR-code concepts
Launch a website in seconds with AI.
Streamline Your Coding Experience with AI Code Helper
Convert any screenshot or design to clean code.