This document shows how to determine the value you should enter for your vCenter server address in an Anthos clusters on VMware (GKE on-prem) admin workstation configuration file or an admin cluster configuration file. In some cases, you might also want to to enter this value in a user cluster configuration file.
In certain situations you must enter an IP address, and in other situations you must enter a hostname. And in some cases, it doesn't matter. You can determine the appropriate value by inspecting the serving certificate of your vCenter server.
Download the serving certificate of your vCenter server, and save it to a file
true | openssl s_client -connect VCENTER_IP:443 -showcerts 2>/dev/null | sed -ne '/-BEGIN/,/-END/p' > vcenter.pem
VCENTER_IP with the IP address of your
Open the certificate file to see the Subject Common Name and the Subject Alternative Name:
openssl x509 -in vcenter.pem -text -noout
The output shows the Subject Common Name (CN). This might be an IP address, or it might be a hostname. For example:
Subject: ... CN = 203.0.113.100
Subject: ... CN = my-host.my-domain.example
The output might also include one or more DNS names under
Subject Alternative Name:
X509v3 Subject Alternative Name: DNS:vcenter.my-domain.example
Choose the Subject Common Name or one of the DNS names under
Subject Alternative Name to use as the value of the vCenter server address
in your configuration file. For example:
vCenter: credentials: address: "203.0.113.1"
vCenter: credentials: address: "my-host.my-domain.example"