How to Run Some Commands to Install Packages Into Dockerfile Within

Hi there,

First of all, loved the speeds I’m getting especially the ease of setting up, once I get the primary installs out of the way!

It’s my first time using and dabbling with the fly.toml file.

I’m trying to play with a Ghost image installation and running it via the Dockerfile setup. My current use case is I wanted to do some additional installations to add some adapter plugins to the pre-existing Ghost image, such as the following:

  1. cd /path/to/your/ghost/installation
  2. npm install ghost-storage-github
  3. mkdir -p content/adapters/storage
  4. cp -r node_modules/ghost-storage-github content/adapters/storage/ghost-storage-github

I have attempted to use the experimental segment using CMD, but have no clear understanding of how it works, and whether I can even run the above installation codes for the Dockerfile as well.

Hope someone can help shed some light on this matter. Much appreciated!

Thank you!

What image are you using or are you using your own Dockerfile?

If you’re using a Dockerfile could you share some if it here?

The types of things you want to add, I’d just add to the Dockerfile and have it based on the ghost image you’re looking to extend but it’ll be easier to help once you share some of your current Dockerfile.

Whether you can run those in the boot command depends on whether the user in the VM has permission to do so. Dockerfiles can specify a non-root user to login as, in which case it might not have permission to add more packages once the image has been made.

Regardles, for the things you want setup I would probably just put them into the Dockerfile itself. Is there a particular reason you were hoping to install them via the experimental command option?

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.