Skip to main content
Hello everyone — welcome back.
Before we move on, here’s a concise, structured recap of deploying CI/CD on Google Cloud. This summary focuses on three core areas you’ll use most often: the Google Cloud SDK and its CLI, practicing the gcloud commands, and Cloud Build as the serverless CI/CD platform.

1) Google Cloud SDK and the gcloud CLI

The Google Cloud SDK is your primary toolbox for managing GCP. It bundles command-line utilities that let you configure projects, manage services, deploy applications, and inspect logs from the terminal. The gcloud command is the central interface for these tasks. Why this matters:
  • Centralized CLI reduces context switching between different consoles.
  • Scripts and automation rely on gcloud for reproducible deployments and admin tasks.
  • SDK includes specialized tools for common services.
Common SDK tools:
ToolPurposeExample
gcloudPrimary CLI for managing projects, IAM, deployments, and moregcloud config set project PROJECT_ID
gsutilCloud Storage operations (upload, download, list)gsutil ls gs://my-bucket
bqBigQuery queries and dataset/table managementbq query 'SELECT COUNT(*) FROM my_dataset.my_table'
kubectlKubernetes cluster management (GKE)kubectl get pods
Install the SDK to get these tools locally and use them consistently across environments. See the official installation guide: Google Cloud SDK.

2) Practicing the gcloud CLI

Practice is essential — these are the commands you’ll use daily and during exams. Work through routine workflows (auth, project selection, storage, BigQuery, Kubernetes) until they become second nature. Quick reference commands:
# Authenticate with Google Cloud
gcloud auth login

# Set the active project
gcloud config set project PROJECT_ID

# Interact with Cloud Storage
gsutil ls gs://my-bucket

# Interact with BigQuery
bq query 'SELECT COUNT(*) FROM `my_dataset.my_table`'

# Interact with Kubernetes clusters (GKE)
kubectl get pods
Tip: Use scripts and CI/CD steps that call these commands to automate repetitive tasks and reduce manual errors.

3) Cloud Build — serverless CI/CD for GCP

Cloud Build is Google Cloud’s serverless CI/CD engine. It executes build steps defined in a cloudbuild.yaml or cloudbuild.json to build, test, push, and deploy artifacts. Cloud Build integrates with source repos (GitHub, Cloud Source Repositories) and triggers automated pipelines on events like push or pull request. What Cloud Build does for you:
  • Builds container images and other artifacts.
  • Runs automated tests and linters.
  • Pushes images to Artifact Registry or Container Registry.
  • Deploys artifacts to Cloud Run, GKE, App Engine, or other targets.
Exam and practical tip: focus on three areas — the SDK and its specialized tools, mastery of gcloud for everyday tasks, and how Cloud Build uses cloudbuild.yaml to automate build/test/deploy pipelines. Knowing how these pieces connect is key to reliable CI/CD on GCP.

Practical example: Deploying a Streamlit app with Cloud Build

Scenario: a data scientist stores a Streamlit app in GitHub and wants an automated deploy to Cloud Run. As the platform engineer or data engineer, you’d implement a repeatable workflow that builds, tests, stores the image, and deploys. Typical workflow:
  • Store app code in a GitHub repo.
  • Create cloudbuild.yaml to:
    • Build a Docker image.
    • Run tests (if any).
    • Push the image to Artifact Registry or Container Registry.
    • Deploy to Cloud Run.
  • Configure a Cloud Build trigger on the GitHub repo to run builds on push/PR.
  • Use gcloud for initial setup and troubleshooting.
High-level commands to run locally or in automation:
# Log in and set project (run locally once)
gcloud auth login
gcloud config set project PROJECT_ID

# Submit a local build using the cloudbuild.yaml (optional)
gcloud builds submit --config=cloudbuild.yaml .

# Deploy a built image to Cloud Run
gcloud run deploy my-streamlit-app \
  --image=gcr.io/PROJECT_ID/my-streamlit-image \
  --platform=managed \
  --region=us-central1 \
  --allow-unauthenticated
This represents the typical flow: source code → Cloud Build (build & test) → Artifact/Container Registry → Cloud Run (deploy).

References and further reading

That’s it for this summary — see you next time.

Watch Video