Namespaces and Google Cloud projects

Config Connector creates Google Cloud resources using Kubernetes configuration. These resources are organized in Kubernetes Namespaces. To function correctly, the Google Cloud project and the destination Kubernetes Namespace must have the same name.

How Config Connector uses Namespaces

Config Connector expects the resource's Namespace to be the same as the Google Cloud project ID.

For example, if you want to create a Cloud Spanner Instance with a name of mySpanner in your project with a project ID of myProject then create a Config Connector SpannerInstance with a name of mySpanner and a namespace of myProject.

You can configure the correct namespace by either annotating your namespace with Config Connector's project ID or setting the default namespace for kubectl.

For more information, see Setting the default Namespace.

Configuring your namespaces

To prevent conflicts, map a single namespace in a single cluster for a Google Cloud project.

Across all of your Config Connector-enabled clusters, your namespace names and override annotations should contain no duplicate values.

To achieve this, we recommend:

  • Installing Config Connector in a single GKE cluster in your project.
  • Using a single namespace with the same name as your project ID or a single namespace with the override annotation with a value of your project ID in all of your projects.
Apakah halaman ini membantu? Beri tahu kami pendapat Anda:

Kirim masukan tentang...

Config Connector Documentation