Deploying Ghost.io

I’m really interested in hosting a blog via Fly.io and was curious if there was any documentation around deploying ghost.io on fly.io? I seem to have trouble when attempting to deploy the provided Dockerfile

When you say trouble can you provide any specific error messages you get when deploying? That could help debug the issue.

Else could this be any help? https://github.com/fly-apps/ghost-litestream

In my attempt to deploy the Ghost.io blog onto Fly.io I copied the following files locally and ran fly deploy.

The logs displayed the following:



Waiting for logs...

2022-02-10T00:36:21.788 runner[ad98d146] iad [info] Starting instance

2022-02-10T00:36:21.845 runner[ad98d146] iad [info] Configuring virtual machine

2022-02-10T00:36:21.846 runner[ad98d146] iad [info] Pulling container image

2022-02-10T00:36:34.454 runner[ad98d146] iad [info] Preparing kernel init

2022-02-10T00:36:34.926 runner[ad98d146] iad [info] Configuring firecracker

2022-02-10T00:36:34.944 runner[ad98d146] iad [info] Starting virtual machine

2022-02-10T00:36:35.140 app[ad98d146] iad [info] Starting init (commit: 0c50bff)...

2022-02-10T00:36:35.168 app[ad98d146] iad [info] Preparing to run: `docker-entrypoint.sh node current/index.js` as root

2022-02-10T00:36:35.176 app[ad98d146] iad [info] Error: UnhandledIoError(Os { code: 13, kind: PermissionDenied, message: "Permission denied" })

2022-02-10T00:36:35.177 app[ad98d146] iad [info] [ 0.085615] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000100

2022-02-10T00:36:35.178 app[ad98d146] iad [info] [ 0.086419] CPU: 0 PID: 1 Comm: init Not tainted 5.12.2 #1

2022-02-10T00:36:35.178 app[ad98d146] iad [info] [ 0.087000] Call Trace:

2022-02-10T00:36:35.178 app[ad98d146] iad [info] [ 0.087298] dump_stack+0x63/0x7e

2022-02-10T00:36:35.179 app[ad98d146] iad [info] [ 0.087660] panic+0xf3/0x2a1

2022-02-10T00:36:35.179 app[ad98d146] iad [info] [ 0.087985] do_exit+0x967/0xb50

2022-02-10T00:36:35.181 app[ad98d146] iad [info] [ 0.090030] entry_SYSCALL_64_after_hwframe+0x44/0xae

2022-02-10T00:36:35.185 app[ad98d146] iad [info] [ 0.093800] RAX: ffffffffffffffda RBX: 00000000005c38b0 RCX: 00000000006f0675

2022-02-10T00:36:46.195 runner[ad98d146] iad [info] Starting instance

2022-02-10T00:36:46.259 runner[ad98d146] iad [info] Configuring virtual machine

2022-02-10T00:36:46.260 runner[ad98d146] iad [info] Pulling container image

2022-02-10T00:36:46.355 runner[ad98d146] iad [info] Unpacking image

2022-02-10T00:36:46.364 runner[ad98d146] iad [info] Preparing kernel init

2022-02-10T00:36:46.829 runner[ad98d146] iad [info] Configuring firecracker

2022-02-10T00:36:46.850 runner[ad98d146] iad [info] Starting virtual machine

2022-02-10T00:36:47.042 app[ad98d146] iad [info] Error: UnhandledIoError(Os { code: 13, kind: PermissionDenied, message: "Permission denied" })

2022-02-10T00:36:47.046 app[ad98d146] iad [info] [ 0.090928] do_exit+0x967/0xb50

2022-02-10T00:36:47.054 app[ad98d146] iad [info] [ 0.098806] RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000 

Hmm well I haven’t looked at the Dockerfile to see exactly what it’s up to, however given it fails at the docker-entrypoint.sh, that would be the first thing to debug.

Since you say you have a local copy, first thing permissions-wise would be to check that is executable. Docker has its own file system but will copy permissions too. So in the folder the docker-entrypoint is in:

chmod +x docker-entrypoint.sh

… and then your local copy definitely is executable. So try another deploy. And see what happens.

1 Like