<p>When launching my Kubernetes deployment for Flower (Celery monitoring service), the following environment variables are generated in the Flower pod by Kubernetes:</p>

<pre><code>FLOWER_PORT=tcp://10.67.97.89:5555
FLOWER_PORT_5555_TCP=tcp://10.67.97.89:5555
FLOWER_PORT_5555_TCP_ADDR=10.67.97.89
FLOWER_PORT_5555_TCP_PORT=5555
FLOWER_PORT_5555_TCP_PROTO=tcp
FLOWER_SERVICE_HOST=10.67.97.89
FLOWER_SERVICE_PORT=5555
FLOWER_SERVICE_PORT_5555=5555
</code></pre>

<p>This is due to the Flower service which is started shortly before the deployment.  However, Flower expects an integer in <code>FLOWER_PORT</code> and aborts.</p>

<p>How can I prevent these environment variables from being created?</p>

<p>You can not prevent creation of these, but you can overwrite them with your own values by setting them explicitly in your deployments pod template. So, if you ie. expect the default value of FLOWER_PORT to be say <code>80</code> instead of <code>tcp://...</code>, all you need to do is put</p>

<pre><code>env:
- name: FLOWER_PORT
  value: "80"
</code></pre>

<p>and that's it.</p>
