So been told this is a support issue and not a bug, so hoping we can get some help here because at this point I need to move 6 sites away from ghost as we cant stay on an old version forever.
Issue Summary
I have multiple setups of ghost running for multiple sites running in docker using ghost version 4.48.9; then I start a new instance of the container with version 5.38.0 we get the following in the logs:
[2023-03-15 03:37:49] INFO Ghost is running in production...
[2023-03-15 03:37:50] INFO Your site is now available on https://******/blog/
[2023-03-15 03:37:50] INFO Ctrl+C to shut down
[2023-03-15 03:37:50] INFO Ghost server started in 37.644s
[2023-03-15 03:38:08] INFO Database is in a ready state.
[2023-03-15 03:38:18] INFO Ghost database ready in 66.288s
[2023-03-15 03:39:29] ERROR Unhandled rejection: connect ETIMEDOUT
connect ETIMEDOUT
Error Code:
ETIMEDOUT
----------------------------------------
Error: connect ETIMEDOUT
at Connection._handleTimeoutError (/var/lib/ghost/versions/5.38.0/node_modules/mysql2/lib/connection.js:202:17)
at listOnTimeout (node:internal/timers:559:17)
at processTimers (node:internal/timers:502:7)
[2023-03-15 03:42:13] INFO Adding offloaded job to the queue
[2023-03-15 03:42:13] INFO Scheduling job clean-expired-comped at 27 45 4 * * *. Next run on: Wed Mar 15 2023 04:45:27 GMT+0000 (Coordinated Universal Time)
[2023-03-15 03:42:13] INFO Adding offloaded job to the queue
[2023-03-15 03:42:13] INFO Scheduling job clean-tokens at 37 0 0 * * *. Next run on: Thu Mar 16 2023 00:00:37 GMT+0000 (Coordinated Universal Time)
[2023-03-15 03:42:15] INFO Ghost booted in 303.155s
[2023-03-15 03:42:15] INFO Adding offloaded job to the queue
[2023-03-15 03:42:15] INFO Scheduling job update-check at 26 29 18 * * *. Next run on: Wed Mar 15 2023 18:29:26 GMT+0000 (Coordinated Universal Time)
[2023-03-15 03:42:16] INFO Running milestone emails job on Wed Mar 15 2023 03:42:16 GMT+0000 (Coordinated Universal Time)
Then if I go to the URL, I get a message about
We'll be right back.
We're busy updating our site to give you the best experience, and will be back soon.
There are no errors in the error logs on the container and when I go to the URL no logs are generated for that request.
This happens on 6 different sites I am running with Ghost. All of them have environment var NODE_ENV=production
Due to ghost cli not working in docker I cant do a ghost ls to check anything else, happy for guidance on how to debug more.
I have only had one instance come up and work after the update, it connects to the same DB server, different DB and it never got the error about ETIMEDOUT
Steps to Reproduce
- have a working ghost instance running and setup with ghost version 4.48.9 on docker (docker-compose file has
image: ghost:4-alpine
) - change the docker-compose file to
image: ghost:5-alpine
- restart service
Ghost Version
5.38.0
Node.js Version
node:16-alpine3.16
How did you install Ghost?
docker image
Database type
MySQL 8
Browser & OS version
chrome 111.0.5563.64
Relevant log / error output
[2023-03-15 03:37:49] INFO Ghost is running in production...
[2023-03-15 03:37:50] INFO Your site is now available on https://******/blog/
[2023-03-15 03:37:50] INFO Ctrl+C to shut down
[2023-03-15 03:37:50] INFO Ghost server started in 37.644s
[2023-03-15 03:38:08] INFO Database is in a ready state.
[2023-03-15 03:38:18] INFO Ghost database ready in 66.288s
[2023-03-15 03:39:29] ERROR Unhandled rejection: connect ETIMEDOUT
connect ETIMEDOUT
Error Code:
ETIMEDOUT
----------------------------------------
Error: connect ETIMEDOUT
at Connection._handleTimeoutError (/var/lib/ghost/versions/5.38.0/node_modules/mysql2/lib/connection.js:202:17)
at listOnTimeout (node:internal/timers:559:17)
at processTimers (node:internal/timers:502:7)
[2023-03-15 03:42:13] INFO Adding offloaded job to the queue
[2023-03-15 03:42:13] INFO Scheduling job clean-expired-comped at 27 45 4 * * *. Next run on: Wed Mar 15 2023 04:45:27 GMT+0000 (Coordinated Universal Time)
[2023-03-15 03:42:13] INFO Adding offloaded job to the queue
[2023-03-15 03:42:13] INFO Scheduling job clean-tokens at 37 0 0 * * *. Next run on: Thu Mar 16 2023 00:00:37 GMT+0000 (Coordinated Universal Time)
[2023-03-15 03:42:15] INFO Ghost booted in 303.155s
[2023-03-15 03:42:15] INFO Adding offloaded job to the queue
[2023-03-15 03:42:15] INFO Scheduling job update-check at 26 29 18 * * *. Next run on: Wed Mar 15 2023 18:29:26 GMT+0000 (Coordinated Universal Time)
[2023-03-15 03:42:16] INFO Running milestone emails job on Wed Mar 15 2023 03:42:16 GMT+0000 (Coordinated Universal Time)