RSS Amplifier

Blog

Labeling a Google Cloud Platform Deployment after it has been created - Stack Overflow

most recent 30 from stackoverflow.com

stackoverflow.comSource feed ↗2 posts

Dormant Last read · last published · next check
Read 2 days ago and current, but nothing has been published for 6 years.

Written by

Latest posts

Answer by Brian McCutchon for Labeling a Google Cloud Platform Deployment after it has been created

There's no need to get the manifest. Using patch is the right idea, but there's an extra header you need to add. Here's an example: dep = self.deploymentManagerService.deployments().get( deployment=deployment, project=project).execute() body = {'labels': [{'key': 'foo', 'value': 'bar'}], 'fingerprint': dep['fingerprint']} req = self.deploymentManagerService.deployments().patch( project=project,…

Labeling a Google Cloud Platform Deployment after it has been created

We have a batch tagger that processes the activity log for newly created resources that we then apply a label to for billing purposes. We are trying to auto-tag our deployments in this way since we discovered that failed deployments were accumulating and incurring a fair amount of cost. My issue is that I cannot tag the deployment. I need to add a global label to a deployment and everything I try…