GoogleCloudPlatform / pbmm-on-gcp-onboarding

GCP Canadian Public Sector Landing Zone overlay on top of the TEF via CFT modules - a secure cloud foundation
https://cloud.google.com/architecture/security-foundations
Apache License 2.0
45 stars 56 forks source link

Cloud Source Unavailable #469

Open hdospitia opened 3 weeks ago

hdospitia commented 3 weeks ago

The repo uses Cloud Source by default, but this API was removed for new customers, effective June 17, 2024. For this reason, the bootstrap-0 step fails (TF apply output):

Error: RequestEnable Project Service "sourcerepo.googleapis.com" for project "prj-b-cicd-rsoy"returned error: failed to enable services: failed on request preconditions: googleapi: Error 403: Permission denied to enable service [sourcerepo.googleapis.com]

image

https://cloud.google.com/source-repositories/docs/reference/rest/

An alternative for the repository resource should be designed.

mromascanu123 commented 3 weeks ago

In fact looking at the code I see in 0-bootstrap a prep.sh script which selects the deployment metchd by copying the relevant files from the builders folder

From what I see the only deployment methods supported are "local" (i.e. running the deployment scripts from a Linux machine) and the pretty much equivalent devops pipeline (under azure-pipelines) which invokes the scripts under automation-scripts and reproduces the manual steps in a devops agent

tackaberry commented 3 weeks ago

This is correct. Cloud Soure Respositories will no longer be available and an alternate path should be chosen. The GitHub version including GH automation is viable and the method is very similar to that of CSR. I'm aware of efforts from the TEF team, as part of v5 (see this issue), to build a methodology that uses Github repo with Cloudbuild automation. We'll reintegrate and use that when its available .

As @mromascanu123 said, the code under azure pipelines provide an alternative method to use Azure DevOps as code repo and automation.