0

The thing is very weird. In GCP. I have a program that first of all creates a new firewall rule to allow ssh, and secondly it launches a new instance. Both of them are linked using TargetTag(Firewall rule) and Tag(new instance).

The tag is always the same, it never changes. The thing is that if I don't delete the firewall rule when I finish and I run again the program, the firewall rule is not made again because already exists but the rule is not working for the new instance.

I know it does not make sense but anyone as any idea of what could it be?

  • There are no known problems with attaching firewall rules to new instances that I know of. This is a basic level feature. If there was a problem, customers would be screaming. This means you need to look into the processes that you are doing. However, there are no details in your question to analyze to point to a solution. – John Hanley Aug 22 '19 at 23:42

2 Answers2

0

I would start by creating an instance manually with the tag you mention and validate if the firewall that has been already created works for this new instance. This will provide light to catch if the issue is with the firewall or the program.

-1

You have to restart the new instance; otherwise, all the firewall rule won't work.

The issue I met is that I created some firewall rules for an instance; then I created another instance; I can see it inherits all the firewall rules; but those firewall rules don't work for the newly created instance until its restarted.

Chee Gong
  • 1
  • 1