upgrade.rst
84 lines
| 2.3 KiB
| text/x-rst
|
RstLexer
r276 | .. _upgrade: | |||
Upgrade rcstack | ||||
=============== | ||||
r287 | It's usually recommended to start with updating the installer itself by running: | |||
r276 | ||||
.. code-block:: bash | ||||
./rcstack self-update | ||||
Then upgrade each stack based on instructions provided from the help output: | ||||
.. code-block:: bash | ||||
r295 | ./rcstack stack-upgrade <STACK_NAME> | |||
r276 | ||||
.. note:: | ||||
./rcstack stack-upgrade rhodecode is a 0 downtime upgrade procedure. | ||||
r365 | This will spawn 2x more nodes to perform the upgrade and then remove the old instances. | |||
This way all incoming traffic will be handled continuously without any interruptions on upgrade | ||||
Example for full upgrade procedure: | ||||
.. code-block:: bash | ||||
./rcstack self-update | ||||
./rcstack stack-upgrade router | ||||
./rcstack stack-upgrade services | ||||
./rcstack stack-upgrade rhodecode | ||||
./rcstack stack-upgrade metrics | ||||
.. note:: | ||||
./rcstack stack-upgrade does scaling of services which might use more RAM to handle the double instance amount. | ||||
To avoid that stop each stack before running stack upgrade. This way services get upgraded without 2x scaling. | ||||
This method however would cause a downtime. | ||||
.. code-block:: bash | ||||
./rcstack self-update | ||||
./rcstack stack router down && ./rcstack stack-upgrade router | ||||
./rcstack stack services down && ./rcstack stack-upgrade services | ||||
./rcstack stack rhodecode down && ./rcstack stack-upgrade rhodecode | ||||
./rcstack stack metrics down && ./rcstack stack-upgrade metrics | ||||
r276 | ||||
r295 | The above upgrade uses default timeouts to wait for any currently ongoing traffic to stop to kill the workers. | |||
There are two additional flags that can be used for a faster upgrade that could let to end users errors, or small downtime | ||||
but will enforce the upgrade to be performed as fast as possible. | ||||
r365 | Fast upgrade with max 65s wait time after new upgraded containers start, and wait 5s before force killing old | |||
containers. This is still 0 downtime upgrade, but stoping existing containers is forced to 5s | ||||
which might result in killed ongoing connections | ||||
r295 | ||||
.. code-block:: bash | ||||
r365 | ./rcstack stack-upgrade rhodecode --stop-wait 65 --docker-stop-wait 5 | |||
r295 | ||||
r287 | ||||
Install specific version | ||||
++++++++++++++++++++++++ | ||||
In order to run a specific version of RhodeCode stack simply follow this: | ||||
.. code-block:: bash | ||||
./rcstack cli set-runtime-image 5.0.0 | ||||
./rcstack stack all down | ||||
./rcstack stack all up -d | ||||