GoogleCloudPlatform / solutions-modern-cicd-anthos

An end-to-end operating model for onboarding and continually deploying services with Anthos.
Apache License 2.0
86 stars 60 forks source link

Add a bash script for setting up Artifact Registry (AR) repository #102

Closed haiyanmeng closed 4 years ago

haiyanmeng commented 4 years ago

1) create an Artifact Registry repo if needed; 2) create a Google service account if needed, and grant the Google service account roles/artifactregistry.writer on the AR repo; 3) create and download a service account key; 4) add the AR repo and the service account key into the app project as GitLab project variables.

haiyanmeng commented 4 years ago

/cc @janetkuo @yuwenma @Liujingfang1 @nan-yu

Liujingfang1 commented 4 years ago

/lgtm

nan-yu commented 4 years ago

LGTM

haiyanmeng commented 4 years ago

@janetkuo , PTAL. Here are the new changes I made since your last LGTM: 1) Add logic to check whether the gitlab access token has sufficent scope; 2) Add support for "--option=" option format 3) Avoid using readonly variables unnecessarily to make the code easier to read