Resolution of the metadata endpoint from within a Istio enabled GKE pod works only with "metadata.google.internal" as the url and not "metadata". No output is produced without the FQDN.
$ curl "http://metadata/computeMetadata/v1/instance/disks/" -H "Metadata-Flavor: Google"
$ curl "http://metadata.google.internal/computeMetadata/v1/instance/disks/" -H "Metadata-Flavor: Google"
0/
Can this be changed to include the FQDN?
|
private static final String METADATA_URL = "http://metadata/computeMetadata/v1/"; |
Resolution of the metadata endpoint from within a Istio enabled GKE pod works only with "metadata.google.internal" as the url and not "metadata". No output is produced without the FQDN.
Can this be changed to include the FQDN?
google-cloud-java/google-cloud-clients/google-cloud-core/src/main/java/com/google/cloud/MetadataConfig.java
Line 36 in 36fbd97