<p>I'm running a kubernetes cluster on GKE and I would like to discover and access the etcd API from a service pod. The reason I want to do this is to add keys to the SkyDNS hierarchy.</p>

<p>Is there a way to discover (or create/expose) and interact with the etcd service API endpoint on a GKE cluster from application pods?</p>

<p>We have IoT gateway nodes that connect to our cloud services via an SSL VPN to ease management and comms. When a device connects to the VPN I want to update an entry in SkyDNS with the hostname and VPN IP address of the device.</p>

<p>It doesn't make sense to spin another clustered DNS setup since SkyDNS will work great for this and all of the pods in the cluster are already automatically configured to query it first.</p>

<blockquote>
  <p>I'm running a kubernetes cluster on GKE and I would like to discover and access the etcd API from a service pod. The reason I want to do this is to add keys to the SkyDNS hierarchy.</p>
</blockquote>

<p>It sounds like you want direct access to the etcd instance that is backing the DNS service (not the etcd instance that is backing the Kubernetes apiserver, which is separate).</p>

<blockquote>
  <p>Is there a way to discover (or create/expose) and interact with the etcd service API endpoint on a GKE cluster from application pods?</p>
</blockquote>

<p>The etcd instance for the DNS service is an internal implementation detail for the DNS service and isn't designed to be directly accessed. In fact, it's really just a convenient communication mechanism between the <code>kube2sky</code> binary and the <code>skydns</code> binary so that <code>skydns</code> wouldn't need to understand that it was running in a Kubernetes cluster. I wouldn't recommend attempting to access it directly.</p>

<p>In addition, this etcd instance won't even exist in Kubernetes 1.3 installs, since <code>skydns</code> is being replaced by a new DNS binary <code>kubedns</code>. </p>

<blockquote>
  <p>We have IoT gateway nodes that connect to our cloud services via an SSL VPN to ease management and comms. When a device connects to the VPN I want to update an entry in SkyDNS with the hostname and VPN IP address of the device.</p>
</blockquote>

<p>If you create a new service, that will cause the cluster DNS to have a new entry created mapping the service name to the endpoints that back the service. What if you programmatically add a service each time a new IoT device registers rather than trying to configure DNS directly?</p>
