Google Professional Cloud Network Engineer Question 569
Select 2Google Cloud PlatformYou are managing a GKE cluster in Google Cloud and need to set up automatic DNS record management for services deployed in your cluster. You want to use Cloud DNS as your DNS provider and external-DNS to dynamically create and manage DNS records for services. Which of the following steps should you take to configure this setup correctly?
- A
Grant the GKE cluster's service account the 'DNS Administrator' role for the Cloud DNS managed zone.
- B
Install and configure the external-DNS operator in the GKE cluster, specifying the Cloud DNS managed zone in the configuration.
- C
Create a Kubernetes ConfigMap to store the Cloud DNS credentials for external-DNS.
- D
Ensure the external-DNS operator is installed in the same namespace as the Kubernetes services it manages.
- E
Configure the external-DNS operator to use a service principal for authentication with Cloud DNS.
Show answer and explanation
Correct answers: A, B
Explanation
To enable automatic DNS record management for GKE services using external-DNS and Cloud DNS, the GKE cluster's service account must have the necessary permissions to manage DNS records. Additionally, the external-DNS operator must be installed and configured to interact with the Cloud DNS managed zone. Other options are either incorrect or unnecessary for this specific setup.
- A. Correct.
Correct: The GKE cluster's service account must have the 'DNS Administrator' role to allow external-DNS to create and manage DNS records in the specified Cloud DNS managed zone.
- B. Correct.
Correct: You need to install and configure the external-DNS operator in the GKE cluster, providing it with the details of the Cloud DNS managed zone so it knows where to create DNS records.
- C. Incorrect.
Incorrect: external-DNS typically uses a Kubernetes Secret (not a ConfigMap) to store Cloud DNS credentials, or it may use the GKE cluster's service account for authentication without requiring explicit credentials.
- D. Incorrect.
Incorrect: external-DNS does not need to be installed in the same namespace as the Kubernetes services. It can manage services across namespaces if configured properly.
- E. Incorrect.
Incorrect: external-DNS does not use service principals for authentication with Cloud DNS. It relies on the GKE service account or explicitly provided credentials.