sautran commented on issue #3183: Not able to set environment variables in 
Heron container
URL: 
https://github.com/apache/incubator-heron/issues/3183#issuecomment-459777533
 
 
   in the AppsV1beta1Controller.java, can we support more user defined env 
variable?
       // setup the environment variables for the container
       final V1EnvVar envVarHost = new V1EnvVar();
       envVarHost.name(KubernetesConstants.ENV_HOST)
           .valueFrom(new V1EnvVarSource()
               .fieldRef(new V1ObjectFieldSelector()
                   .fieldPath(KubernetesConstants.POD_IP)));
   
       final V1EnvVar envVarPodName = new V1EnvVar();
       envVarPodName.name(KubernetesConstants.ENV_POD_NAME)
           .valueFrom(new V1EnvVarSource()
               .fieldRef(new V1ObjectFieldSelector()
                   .fieldPath(KubernetesConstants.POD_NAME)));
       container.setEnv(Arrays.asList(envVarHost, envVarPodName));
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to