GKE Ingress host (incorrectly) reverted back to old value after new Helm deploy

Viewed 52

We have a problem with in GKE with an Ingress that keeps switching back to an old host when re-deploying with Helm (from script in Google Cloud Build).

The Ingress was first created with host X and then the build script was changed to use host Y. After that, 2 times of 3, the Ingress is using host X instead of host Y.

The log from the build script always show the correct host Y being used.

We have tested to delete the Ingress and recreate it from scratch, but the problem persists.

We have done the same process of switching Ingress host in the build/deploy scripts before, never had a problem. Until now.

We are not Kubernetes experts, maybe there is something simple we are missing.

Anyone have any ideas?


Update 2022-09-19:

So it turns out the issue originates in Cloud Build. The build for some unknown reason creates the ingress twice (only one gets logged though). Both happen in the same build step, but with som time in between them. First the ingress is created/updated with the old host, and 30-60 seconds later the "real" ingress is created with the correct values. But it seems like that one fails to override the old ingress.

Even when changing the resource names, the old ingress get recreated with the old host and the old resource name. This makes it clear to me this is a bug in Cloud Build.

After creating a new trigger (an exact duplicate), everything seems to be working as expected again.

0 Answers
Related