We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4843256 commit d89628cCopy full SHA for d89628c
alts/src/main/java/io/grpc/alts/HandshakerServiceChannel.java
@@ -16,6 +16,7 @@
16
17
package io.grpc.alts;
18
19
+import com.google.common.base.MoreObjects;
20
import io.grpc.CallOptions;
21
import io.grpc.Channel;
22
import io.grpc.ClientCall;
@@ -39,7 +40,10 @@
39
40
final class HandshakerServiceChannel {
41
42
static final Resource<Channel> SHARED_HANDSHAKER_CHANNEL =
- new ChannelResource("metadata.google.internal.:8080");
43
+ new ChannelResource(
44
+ MoreObjects.firstNonNull(
45
+ System.getenv("GCE_METADATA_HOST"), "metadata.google.internal.:8080"));
46
+
47
48
/** Returns a resource of handshaker service channel for testing only. */
49
static Resource<Channel> getHandshakerChannelForTesting(String handshakerAddress) {
0 commit comments