Giter VIP home page Giter VIP logo

cloud-run-app-sample's Introduction

cloud-run-app-template

This is a template for a Cloud Run app.

You can initialize a GitHub repository to manage Cloud Run services with Terraform:

  • Deploy a Cloud run service with Terraform
  • Set up a GitHub Actions workflow for the Terraform

Steps

  1. Create a repo from this template.

    gh repo create <your new repo name> --template=nakabonne/cloud-run-app-template
    
  2. Create a GCS bucket for Terraform backend if needed (optional).

    gsutil mb -p "<gcp project>" -l "<region>" gs://"<bucket>"
    
  3. Write your own config files.

    terraform.tfvars:

    project      = "<gcp project>"
    region       = "<region>"
    service_name = "<Cloud Run service name>"

    terraform.tfbackend:

    bucket  = "<bucket for Terraform state>"
  4. Run terraform init -backend-config=terraform.tfbackend

  5. Run terraform apply

  6. Set up GitHub Actions secrets PROVIDER_NAME and SA_EMAIL.

    gh secret set PROVIDER_NAME --body=$(terraform output github_actions_provider_name | tr -d '"')
    gh secret set SA_EMAIL --body=$(terraform output github_actions_sa_email | tr -d '"')
    
  7. Push to your repo.

For more details, please read terraform.

Application

TBD

Ref

  1. terraform-google-cloud-run
  2. terraform-google-modules/terraform-google-github-actions-runners

cloud-run-app-sample's People

Contributors

nakamasato avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.