0

Is there a way to set default tags for IPs or VMs in a project? We have separate projects connected via VPC and it would be nice to be able to have a tag for things in a project for things like firewall rules. It's clear how to set default labels in metadata for a project and I can see that label keys used to automatically act as network tags but that doesn't happen anymore.

1 Answer 1

0

You can only apply tags on VMs then it can be used to apply firewall rules and also act as a label. See steps below on how to add a tag on an existing VM.

  1. Go to Compute engine > VM instance page
  2. Click the target instance
  3. Under Network tags, specify a tag
  4. Click Save

For more information about the topic or equivalent cloud shell command, visit the official GCP documentation here.

2
  • So, no way no way to set a default tag for VMs in a project? I know how to add tags individually, both at create and after the fact, but it seems like such obvious feature to have that it's hard for me to accept that it doesn't exist. Maybe I'm looking at it wrong? Maybe there's some other way to refer to a whole project when creating firewall and routing rules?
    – xaocon
    Oct 21, 2020 at 17:59
  • Yes, the default network tags cannot be set.
    – Alex G
    Oct 29, 2020 at 6:38

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .