Deploying a plugin / custom deployment with Docker


Hi, I have an automated docker deployment setup deploying reactioncommerce/reaction:latest
But I want to add in plugins/themes.

So my options are to:

Fork reactioncommerce/reaction and create new docker images in dockerhub.

or I was thinking i could paste my plugin files into the meteor build after docker has downloaded the repo but before reaction is run. Looking at the docker file in base it may be hard to get something to happen between scripts.

Any help would be great thanks


You can run reaction init to start a new local project in development, then add your custom plugin(s) to /imports/plugins/custom. When you run reaction locally in development or do a docker build ... your plugin will get loaded and built just like the internal plugins do.

You can check out the example plugin to see the standard structure.

Essentially, you just need to add one (or all) of the following files and the plugin loader will import them automatically…


Also, see the accompanying docs for creating plugins/themes.


i don’t understand how this works on my sever though ? At the moment I upload a docker file and my server pulls reaction and builds/runs it. How can my plugin get inside that process ?

And do i have to fork the reactioncommerce/reaction as well to create custom plugins ? Because reaction init sets up gitignore files so that none of the reaction code gets pushed to my repo… ? (This also stops me from team work with plugins). I’m still trying (struggling) to understand the layout of reaction.


don’t worry i think i have most of this sorted now.


How did you solve it?

Ideally, I’d like to use the Dockerfile approach and add plugins afterwards, maybe from a repo or something.

Would you like to share how your process looks like?



I ended up forking the reaction repo, then adding in plugins. Then building my own docker image and deploying that. I think that is the normal way to go about this.

However it could also be possible to use docker to add in a step between line 22 and 60 of this file executes in the base image here:

…maybe make a .sh file that install git and pulls code from your repo and dumps it in the correct place in the $APP_SOURCE_DIR. I think you would need to ask someone who is really good with docker if it is possible with out modifying the base image.