Docker Image with Node that will auto-pull codebase using the specified Git repo
10K+
Docker Image with Node and with Automatic Git Deployment functionalities including Webhooks
The following flags are a list of all the currently supported options that can be changed by passing in the variables to docker with the -e flag.
/var/www/html to your own settingOne of the nice features of this container is its ability to pull code from a git repository with a couple of environmental variables passed at run time.
Note: You need to have your SSH key that you use with git to enable the deployment. I recommend using a special deploy key per project to minimise the risk.
The container expects you pass it the SSH_KEY variable with a base64 encoded private key. First generate your key and then make sure to add it to github and give it write permissions if you want to be able to push code back out the container. Then run:
base64 -w 0 /path_to_your_key
Note: Copy the output be careful not to copy your prompt
To run the container and pull code simply specify the GIT_REPO URL including git@ and then make sure you have also supplied your base64 version of your ssh deploy key:
sudo docker run -d -e '[email protected]:ngineered/ngineered-website.git' -e 'SSH_KEY=BIG_LONG_BASE64_STRING_GOES_IN_HERE' richarvey/nginx-php-fpm
To pull a repository and specify a branch add the GIT_BRANCH environment variable:
sudo docker run -d -e '[email protected]:ngineered/ngineered-website.git' -e 'GIT_BRANCH=stage' -e 'SSH_KEY=BIG_LONG_BASE64_STRING_GOES_IN_HERE' richarvey/nginx-php-fpm
docker-hook listens to incoming HTTP requests and triggers your specified command.
It is included in /usr/bin/docker-hook
There is a listener script copied to /usr/bin/hook-listener that will auto-start
Content type
Image
Digest
Size
274 MB
Last updated
over 9 years ago
docker pull eduwass/docker-node-git