GKE - Is it a way to customize network endpoint name?

2/27/2020

I created clusters for production and staging. You know those configuration should be same as possible.

When I created Network endpoint groups for each clusters, those name are much alike and I cannot distinguish them by heart.

See first and last one: enter image description here

In the document, https://cloud.google.com/kubernetes-engine/docs/how-to/standalone-neg#create_a_service

The NEG's name has this format: k8s1-cluster-uid-namespace-service-port-random-hash

So, my options are change namespace or service name, but changing those names make unwanted differences in production and staging environment setup.

Are there any idea about solving this problem?

Thanks.

-- hiroshi
google-kubernetes-engine

1 Answer

2/27/2020

As you mentioned, the documentation says the name of the NEG was generated automatically using the formula:

k8s1-cluster-uid-namespace-service-port-random-hash

So, you only can modify the name if you modify some of this items:

  • Use a different cluster (as you already have)
  • Modify the namespace
  • Modify the service-name
-- ginerama
Source: StackOverflow