fuel-web/fuel_upgrade_system
Igor Kalnitsky 740aaea86b
Change docker upgrade steps
We used to have an 'error-prone' approach of making Docker upgrades,
and in really rare cases we had an old container in 'running' state
instead of new one.

Here's the steps when issue occurs:

* One container isn't running due to some reason (for instance, it
  failed). The supervisor scheduled to start it again soon.
* The fuel_upgrade script stops supervisor's processes. They will be
  stopped and won't be started again by supervisor (even if they have
  autostart=true setting).
* The container, which wasn't run by the time we was stopping them,
  is untouched. It's still scheduled to be running soon.
* The fuel_upgrade script stops Docker containers, but one of them
  will be starting again and again because of that working supervisor
  process.

In order to avoid this situation, we have to do the following things:

* Point supervisor to new config folder (which is empty by now).
* Restart supervisor, so it forget old configs and will use no of them.
* Upload images and create new containers.
* Generate new supervisor configs and restart supervisor in order to
  apply them (supervisor's processes will be attached automatically
  to running docker containers).

Signed-off-by: Igor Kalnitsky <igor@kalnitsky.org>

Change-Id: Ibc133b4471878efeffeb232192b4540d26401fae
Closes-Bug: #1441693
2015-04-15 11:39:37 +03:00
..
fuel_package_updates Add fuel_package_updates package 2015-04-13 10:29:00 +02:00
fuel_upgrade Change docker upgrade steps 2015-04-15 11:39:37 +03:00