I want to promote a release from environment A to environment B through cli. However, I looked through the 'gcloud deploy releases/rollouts/targets' and could not figure out how to get the latest success release name. Thanks.
Solved! Go to Solution.
Hi @pwei100 ,
This gcloud command should promote the last successful release against a target:
gcloud deploy releases promote --release=$(gcloud deploy targets describe dev --delivery-pipeline=$the_pipeline --region=$the_region --format="value('Latest release')") --delivery-pipeline=$the_pipeline --region=$the_region
Does this help?
Hi @pwei100 ,
This gcloud command should promote the last successful release against a target:
gcloud deploy releases promote --release=$(gcloud deploy targets describe dev --delivery-pipeline=$the_pipeline --region=$the_region --format="value('Latest release')") --delivery-pipeline=$the_pipeline --region=$the_region
Does this help?
Yes, that's what I need.