Public metrics are hosted at: https://grafana.prod.discovery.etcd.io/d/uiLwPyPWk/discoveryserver?orgId=2
This repo contains the code to provision the infrastructure and the Kubernetes configurations to operate the public discovery.etcd.io service.
- Helm ~> v3.0.0 - Install latest version for your OS.
- Terraform ~> v0.12.15 Please download the proper package for your operating system and architecture.
The infrastructure is built using cloudkite terraform modules, which are used to provision infrastructure in Google Cloud Platform. The following modules have been used:
-
vpc: The vpc module contains Terraform code to provision a GCP Virtual Private Cloud. See VPC docs.
-
gke: The folder contains Terraform code to deploy a GKE Private Cluster.
The infrastructure main code is created per environment, and there are two environments:
Choose an environment - that is, move to the dev or to prod folder in order to run Terraform commands.
Next step is to apply Terraform for the chosen environment. To ensure that it is configured correctly, apply it and get the expected output, go to the project's terraform folder and follow the README instructions.
The discoveryserver image is published to Artifact Registry in the etcd-io-dev project
(us-docker.pkg.dev/etcd-io-dev/discoveryserver), as gcr.io / Container Registry was shut down by Google in 2025.
For clusters to pull it, the gke_service_accounts of both environments must have the role
roles/artifactregistry.reader on that repository (prod pulls cross-project from etcd-io-dev).
gcloud command to grant the role:
gcloud artifacts repositories add-iam-policy-binding discoveryserver --location=us --project=etcd-io-dev --member="serviceAccount:[SERVICE_ACCOUNT_EMAIL]" --role=roles/artifactregistry.reader
After applying terraform, a GKE cluster will be up and running in the VPC created. Now the cluster is ready to get deployments.
To get the public discovery service running, the following releases have to be installed:
- Nginx Ingress Controller: Used for routing traffic from beyond the cluster to internal Kubernetes Services. To install follow instructions in README.
- certmanager: Is the TLS/SSL certificate management controller, and to get it deployed follow the README.
- etcd-operator: Is used to configure and manage etcd clusters. This is a pre-requisite to have configured properly the discoveryserver release. To install it follow instructions in README.
- discoveryserver: Is a service that bootstrap new etcd clusters using an existing one. This service helps when the IPs of your cluster peers are not known ahead of time. To install the release follow instructions in README.
Hit the discovery service via kubectl proxy
kubectl proxy
curl http://localhost:8001/api/v1/namespaces/default/services/discoveryserver/proxy/new
Execute etcdctl on the cluster
kubectl exec -it $(kubectl get pods -l app=etcd -o jsonpath='{.items[0].metadata.name}') -- /usr/local/bin/etcdctl watch '' --prefix