Description
Hi team,
I have been trying to start my ghost container which was built by docker-compose. But I am getting the following error on the ghost container:
[2022-07-09 22:52:37] WARN Ghost was running for a few seconds
[2022-07-09 22:54:33] ERROR (Code: -99)
(Code: -99)
"There was an error starting your server."
"Please use the error code above to search for a solution."
Error ID:
1953d2c0-ffda-11ec-847e-8981c1a1bb63
InternalServerError: (Code: -99)
at Server. (/var/lib/ghost/versions/5.2.4/core/server/ghost-server.js:95:34)
at Server.emit (node:events:527:28)
at emitErrorNT (node:net:1399:8)
at processTicksAndRejections (node:internal/process/task_queues:83:21)
[2022-07-09 22:54:33] WARN Ghost is shutting down
[2022-07-09 22:54:33] WARN Ghost has shut down
My docker-compose.xml as follows:
services:
ghost:
image: ghost:latest
container_name: ghost-test
hostname: ghost-test
volumes:
- /volume1/docker/ghost-test/config.production.json:/var/lib/ghost/config.production.json #overwrite default settings
- /volume1/docker/ghost-test/content:/var/lib/ghost/content
expose:
- "3307"
environment: # this section can be commented to start in dev mode by default
- NODE_ENV=production # set either production or development, then it will load the respective config
links:
- MySQL
And my config.production.json is as follows:
{
"url": "http://ghost.example.com",
"server": {
"port": 2369,
"host": "192.167.1.17"
},
"database": {
"client": "mysql",
"connection": {
"host": "mysql",
"port": 3307,
"user": "ghosttest",
"password": "ghostpassword",
"database": "ghostdb",
"charset": "utf8mb4"
}
},
"mail": {
"from": "'Custom Name' [email protected]",
"transport": "SMTP",
"logger": true,
"options": {
"host": "",
"secureConnection": false,
"auth": {
"user": "",
"pass": ""
}
}
},
"logging": {
"transports": [
"file",
"stdout"
]
},
"process": "systemd",
"paths": {
"contentPath": "/var/lib/ghost/content"
}
}
Not quite sure what's wrong. I have been trying to set on my environment without using bind environment variable, but that's the root cause.