Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI/CD for Cloud Run deployment #62

Open
AtulanZaman opened this issue Jun 4, 2024 · 0 comments
Open

CI/CD for Cloud Run deployment #62

AtulanZaman opened this issue Jun 4, 2024 · 0 comments

Comments

@AtulanZaman
Copy link

AtulanZaman commented Jun 4, 2024

Currently, the implementation for cloud run (CR) deployment is such that, we create an image using a "local_provisioner" and create the cloud run resource in Terraform referencing the latest version of the newly created container.

Problem with this approach is that if there are any updates to the implementation of the service and a new image is pushed, the CR instance doesn't get updated, even if Terraform is re-ran, since the version of the image is not saved in state due to the "latest" image reference.

My recommendation would be, as part of the submission service component, we also generate a cloudbuild or github actions workflow for the submission service, so that if any changes are pushed to the submission service, we build the new image and deploy the new image to the CR instance, using a templatized workflow. Here are two references from Cloud Build and Github Actions:

https://cloud.google.com/build/docs/deploying-builds/deploy-cloud-run
https://github.com/google-github-actions/deploy-cloudrun

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant