New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
domain_name_label missing under network_profile part of azurerm_kubernetes_cluster #5085
Comments
@shreekant Do you want to assign a custom DNS name to the K8s API server or to one of your ingresses? The former is AFAIK not possible as Azure does not give you any control over this IP address. You can of course create your own CNAME or A record. The latter is possible e.q. by creating a static public IP address, giving it a custom DNS name and creating an ingress controller that uses this address. Check out this doc for more information. The whole process can be realized using Terraform. Feel free to ask for assistance. |
@brennerm : I want to assign DNS name to the k8s api and not for the ingress. As mentioned in the description we cannot use the |
The network_profile block is used for the cluster internal network configuration. The K8s API address is unrelated to this. Azure only gives you the option to add a prefix to it's DNS name.
This will result in a DNS name for your API server similar to What you can do is access the DNS name ( Hope this helps. 👍 |
@brennerm : Thanks for reply! |
Ahh, guess I understand your problem now. Had a look at the azure-go-sdk and it is possible to A. to get the ID of the public IP address that Azure creates using the ManagedClusterLoadBalancerProfile. @shreekant What would be your preferred option? |
@brennerm : Either of the option is ok for me, preferably assigning the DNS label from network_profile would be easy. |
@brennerm thinking about this from our side it'd probably make more sense to pass in the IP of a Public IP Address, rather than letting Azure create it - since this means we're also able to tear it down when the AKS Cluster is destroyed (and track changes to it as needed). We've implemented both in some other cases and it's confused users in some cases - as such I'm not opposed to either, but I think the only way we're going to know for sure would be by prototyping that - WDYT? |
@brennerm, @tombuildsstuff any updates? |
This issue was originally opened by @shreekant as hashicorp/terraform#23572. It was migrated here as a result of the provider split. The original body of the issue is below.
Current Terraform Version
Use-cases
I am creating AKS by using
azurerm_kubernetes_cluster
resource under that I am usingnetwork_profile
- would like to addCustom name
forPublic IP
and I also need to set DNS name (domain_name_label
) which is currently not supported.I tried
azurerm_public_ip
but cannot associate k8s to it and more over after using azurerm_kubernetes_cluster and azurerm_public_ip - ending up having 2 public ip's.Attempted Solutions
I tried
azurerm_public_ip
but cannot associate k8s to it and more over after using azurerm_kubernetes_cluster and azurerm_public_ip - ending up having 2 public ip's.Proposal
Under
network_profile
there should be an option to have custom name and domain_name_label for Public IP.References
The text was updated successfully, but these errors were encountered: