Labeling a Google Cloud Platform Deployment after it has been created - Stack Overflow · Sep 23, 2020
Answer by Brian McCutchon for Labeling a Google Cloud Platform Deployment after it has been created
0Sign in to vote or save
This page did not load. You can still read it on the original site — the toolbar below keeps your place in the directory.
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,…

Comments
Nothing yet. Say the first thing.
Sign in to join the conversation.