Upgrading docker cms 1.8.10

Hi!

I m trying to upgrade my cms v.1.8.10 to the latest version. I m trying to upgrade is using docker. What i did:

  1. i backed up the shared directory
  2. i followed the official docker upgrade tutorial posted here on the forum
  3. i downloaded the latest tar version, and extracted the tar file
  4. ran the docker pull command
  5. copied back the shared dir
  6. modified the docker-compose.yml file. I rewrote the volumes location to point to the correct directory (example: -“opt/xibo/shared/cms/custom:/var/www/cms/custom:z” ) I rewrote the password to the mysql db to the old one, in the config.env file
  7. ran docker-compose up in the /opt/xibo/ dir as root

All the steps above were executed as root in the /op/xibo/ directory. Unfortunately the webserver doesnt come up.

[root@localhost xibo]# docker ps -a
CONTAINER ID        IMAGE                                        COMMAND                  CREATED             STATUS                            PORTS                NAMES
331589fbae1f        ianw/quickchart                              "node --max-http-hea…"   About an hour ago   Up About an hour                  3400/tcp             xibo_cms-quickchart_1
61f4d1ee5e2f        memcached:alpine                             "docker-entrypoint.s…"   About an hour ago   Up About an hour                  11211/tcp            xibo_cms-memcached_1
33dd6bd458fa        ghcr.io/xibosignage/xibo-cms:release-4.1.2   "/entrypoint.sh"         About an hour ago   Up About an hour                  0.0.0.0:80->80/tcp   xibo_cms-web_1
526e303f03fc        ghcr.io/xibosignage/xibo-xmr:0.11            "docker-php-entrypoi…"   About an hour ago   Restarting (134) 31 seconds ago                        xibo_cms-xmr_1
6366a74a4f66        mysql:8.0                                    "docker-entrypoint.s…"   About an hour ago   Restarting (1) 33 seconds ago                          xibo_cms-db_1
4a1d0cd32ba6        hello-world                                  "/hello"                 6 years ago         Exited (0) 6 years ago                                 thirsty_archimedes

[root@localhost xibo]# docker-compose logs
Attaching to xibo_cms-quickchart_1, xibo_cms-memcached_1, xibo_cms-web_1, xibo_cms-xmr_1, xibo_cms-db_1
cms-quickchart_1  | {"name":"quickchart","hostname":"331589fbae1f","pid":1,"level":30,"msg":"Telemetry is enabled","time":"2024-11-18T11:32:36.495Z","v":0}
cms-quickchart_1  | Mon, 18 Nov 2024 11:32:37 GMT body-parser deprecated undefined extended: provide extended option at index.js:38:17
cms-quickchart_1  | {"name":"quickchart","hostname":"331589fbae1f","pid":1,"level":30,"msg":"Setting request timeout: 5000 ms","time":"2024-11-18T11:32:37.192Z","v":0}
cms-quickchart_1  | {"name":"quickchart","hostname":"331589fbae1f","pid":1,"level":30,"msg":"NODE_ENV: production","time":"2024-11-18T11:32:37.192Z","v":0}
cms-quickchart_1  | {"name":"quickchart","hostname":"331589fbae1f","pid":1,"level":30,"msg":"Listening on port 3400","time":"2024-11-18T11:32:37.192Z","v":0}
cms-web_1         | Waiting for MySQL to start - max 300 seconds
cms-web_1         | MySQL started
cms-web_1         | Configuring MySQL cnf file
cms-web_1         | Updating settings.php
cms-web_1         | ERROR 2002 (HY000): Can't connect to MySQL server on 'cms-db' (115)
cms-web_1         | New install
cms-web_1         | Provisioning Database
cms-web_1         | ERROR 2002 (HY000): Can't connect to MySQL server on 'cms-db' (115)
cms-web_1         | Phinx by CakePHP - https://phinx.org.
cms-web_1         |
cms-web_1         | using config file /var/www/cms/phinx.php
cms-web_1         | using config parser php
cms-web_1         | using migration paths
cms-web_1         |  - /var/www/cms/db/migrations
cms-web_1         | warning no environment specified, defaulting to: production
cms-web_1         | using adapter mysql
cms-web_1         | using database cms
cms-web_1         | ordering by creation time
cms-web_1         | PDOException: SQLSTATE[HY000] [2002] Connection refused in /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php:86
cms-web_1         | Stack trace:
cms-web_1         | #0 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php(86): PDO->__construct()
cms-web_1         | #1 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/MysqlAdapter.php(158): Phinx\Db\Adapter\PdoAdapter->createPdoConnection()
cms-web_1         | #2 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php(163): Phinx\Db\Adapter\MysqlAdapter->connect()
cms-web_1         | #3 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php(226): Phinx\Db\Adapter\PdoAdapter->getConnection()
cms-web_1         | #4 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php(247): Phinx\Db\Adapter\PdoAdapter->query()
cms-web_1         | #5 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php(383): Phinx\Db\Adapter\PdoAdapter->fetchAll()
cms-web_1         | #6 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php(355): Phinx\Db\Adapter\PdoAdapter->getVersionLog()
cms-web_1         | #7 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Db/Adapter/AdapterWrapper.php(205): Phinx\Db\Adapter\PdoAdapter->getVersions()
cms-web_1         | #8 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Migration/Manager/Environment.php(254): Phinx\Db\Adapter\AdapterWrapper->getVersions()
cms-web_1         | #9 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Migration/Manager.php(315): Phinx\Migration\Manager\Environment->getVersions()
cms-web_1         | #10 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Console/Command/Migrate.php(122): Phinx\Migration\Manager->migrate()
cms-web_1         | #11 /var/www/cms/vendor/symfony/console/Command/Command.php(298): Phinx\Console\Command\Migrate->execute()
cms-web_1         | #12 /var/www/cms/vendor/symfony/console/Application.php(1040): Symfony\Component\Console\Command\Command->run()
cms-web_1         | #13 /var/www/cms/vendor/symfony/console/Application.php(301): Symfony\Component\Console\Application->doRunCommand()
cms-web_1         | #14 /var/www/cms/vendor/robmorgan/phinx/src/Phinx/Console/PhinxApplication.php(70): Symfony\Component\Console\Application->doRun()
cms-web_1         | #15 /var/www/cms/vendor/symfony/console/Application.php(171): Phinx\Console\PhinxApplication->doRun()
cms-web_1         | #16 /var/www/cms/vendor/robmorgan/phinx/bin/phinx(28): Symfony\Component\Console\Application->run()
cms-web_1         | #17 /var/www/cms/vendor/bin/phinx(119): include('...')
cms-web_1         | #18 {main}
cms-web_1         |

Hi c.steve.

your message suggests that you have upgraded directly from 1.8.10 to 4.1.2, which is not recommended. You will need to upgrade your CMS incrementally, 1.8.13, to 2.3.17, to 3.3.12 and finally 4.1.2.

Please roll back to 1.8.10 using your backups of the database and media library, then start the process again, this time making sure to complete each upgrade. Make sure that you test each upgrade before you proceed to the next, otherwise you may find it hard to undo any issues that may occur during the process.

This is the official documentation for upgrading your CMS. Please make sure to follow the steps and to create backups of your database and media library before you attempt each upgrade.

Thank you for the reply. Honestly i did not have any complicated campaigns, and for anybody who stumbles on this thread, i did not manage to import the old layouts even after a clean fresh installation. Some sort of json error came up. A mess. Had to recreate all my layouts manually.