92278cfd5b
Signed-off-by: Tihomir Jovicic <tihomir.jovicic.develop@gmail.com>
1.2 KiB
1.2 KiB
slug |
---|
/learn/106-cloudrun |
Dagger 106: deploy to CloudRun
This tutorial illustrates how to use dagger to push and deploy Docker images to CloudRun.
import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem';
Deploy an application to GCP Cloud Run
This example shows how to deploy an application to GCP Cloud Run. Read the deployment plan
NOTE: this example requires an EKS cluster to allow authentication with your AWS credentials; but can easily be adapter to deploy to any Kubernetes cluster.
Components:
How to run:
-
Initialize a new workspace
cd ./cloud-run-app dagger init
-
Create a new environment
dagger new cloud-run-app cp *.cue ./.dagger/env/cloud-run-app/plan/
-
Configure the Cloud Run service
dagger input text serviceName MY_APP_NAME dagger input text region MY_GCP_REGION dagger input text image MY_GCR_IMAGE_NAME dagger input text gcpConfig.project MY_GCP_PROJECT dagger input secret gcpConfig.serviceKey -f MY_GCP_SERVICE_KEY_FILE
-
Deploy!
dagger up