# Docker upgrading - Portainer ENV variables

**URL:** <https://community.openhab.org/t/docker-upgrading-portainer-env-variables/136580>\
**Category:** Installation\
**Tags:** docker, update, portainer\
**Created:** [June 11, 2022, 1:31pm UTC](https://community.openhab.org/t/docker-upgrading-portainer-env-variables/136580 "2022-06-11T13:31:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![MartOs](https://community.openhab.org/user_avatar/community.openhab.org/martos/32/64748_2.png) [@MartOs](https://community.openhab.org/u/MartOs)\
**Post date:** [June 11, 2022, 1:31pm UTC](https://community.openhab.org/t/docker-upgrading-portainer-env-variables/136580/1 "2022-06-11T13:31:28Z")

</div>

Hi,

Can someone please explain what this means and what I actually need to do?

The text below is from the Docker Hub page

> **[openhab/openhab - Docker Image](https://hub.docker.com/r/openhab/openhab/)**

### Portainer

The default values of ENV variables are always stored by Portainer (see [portainer/portainer#2952](https://github.com/portainer/portainer/issues/2952)). This causes issues such as endless restart loops when upgrading the container with Portainer. To resolve this issue when upgrading openHAB, first remove all default (non-overridden) ENV variables before starting the new container.

How do I ‘remove all default ENV variables’?

---

<div class="post-metadata">

**Author:** ![JustinG](https://community.openhab.org/user_avatar/community.openhab.org/justing/32/55948_2.png) [@JustinG](https://community.openhab.org/u/JustinG)\
**Post date:** [June 11, 2022, 3:24pm UTC](https://community.openhab.org/t/docker-upgrading-portainer-env-variables/136580/2 "2022-06-11T15:24:44Z")

</div>

I do not know the original motivation behind that warning, but I can say that it has never impacted me. I’ve been running OH in docker since 3.0 and often use Portainer for quick administration, particularly upgrades. If you have your image set right (most of the time I use openhab/openhab:milestone) then you just need to press the `recreate` button at the top of the container details page, check the `Pull latest image` box and set it to go.

---

<div class="post-metadata">

**Author:** ![MartOs](https://community.openhab.org/user_avatar/community.openhab.org/martos/32/64748_2.png) [@MartOs](https://community.openhab.org/u/MartOs)\
**Post date:** [June 11, 2022, 7:14pm UTC](https://community.openhab.org/t/docker-upgrading-portainer-env-variables/136580/3 "2022-06-11T19:14:46Z")

</div>

Whenever I do it like that it goes into a loop. I have to delete everything, pull it, then add back in all my own personal files. PITA

---

<div class="post-metadata">

**Author:** ![JustinG](https://community.openhab.org/user_avatar/community.openhab.org/justing/32/55948_2.png) [@JustinG](https://community.openhab.org/u/JustinG)\
**Post date:** [June 11, 2022, 8:57pm UTC](https://community.openhab.org/t/docker-upgrading-portainer-env-variables/136580/4 "2022-06-11T20:57:08Z")

</div>

Strange. I wonder what I did differently. I am not enough of a docker guru to have done whatever it was on purpose, so alas, I can’t really say.

---

<div class="post-metadata">

**Author:** ![system](https://community-openhab-org.s3-eu-central-1.amazonaws.com/original/2X/6/6a52f2ac5d00e4c7b50471a354b3a9221188be90.png) [@system](https://community.openhab.org/u/system)\
**Post date:** [July 23, 2022, 12:57pm UTC](https://community.openhab.org/t/docker-upgrading-portainer-env-variables/136580/5 "2022-07-23T12:57:33Z")

</div>

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.
