title: Kubernetes deployment without a port
body: <p>I have a service which is long-running (in a <code>while 1</code> loop) and processes payloads via GCloud pub/sub, after which it writes the result to a DB.</p>
  
  <p>The service doesn't need to listen on any port.</p>
  
  <p><strong>What would the declarative YAML config look like for <code>Kind=Deployment</code>?</strong></p>
  
  <p>I understand <code>ClusterIP</code> is the default type, and the docs <a href="https://kubernetes.io/docs/concepts/services-networking/service/#headless-services" rel="noreferrer">go on to say</a> that a headless service just has to define <code>spec.clusterIP</code> as <code>None</code>.</p>
  
  <p>(A better practice would probably be to modify the worker to exit after a successful payload processing, and change the <code>Kind</code> to <code>Job</code>, but this is in the backlog)</p>