Created
July 10, 2016 15:36
-
-
Save jkrup/7913365400fd3de24204352b466b60af to your computer and use it in GitHub Desktop.
Very basic CircleCI config for MeteorJS on Docker using rsync (capable of deploying MeteorJS on AliCloud servers)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
machine: | |
node: | |
version: 0.10.35 | |
services: | |
- docker | |
dependencies: | |
pre: | |
- docker build -t mazlix/testci . | |
test: | |
override: | |
- docker run -d -e ROOT_URL=http://localhost -p 80:80 mazlix/testci; sleep 10 | |
- curl --retry 10 --retry-delay 5 -v http://localhost | |
deployment: | |
prod: | |
branch: master | |
commands: | |
- mkdir -p ~/docker; docker save mazlix/testci > ~/docker/image.tar | |
- rsync -zP ~/docker/image.tar root@198.199.92.163:~ | |
- ssh root@198.199.92.163 "docker kill \$(docker ps -q); docker load -i image.tar; docker run -d -e ROOT_URL=http://testci.bokuga.com -p 80:80 mazlix/testci" | |
- rsync -zP ~/docker/image.tar root@101.201.38.83:~ | |
- ssh root@101.201.38.83 "docker kill \$(docker ps -q); docker load -i image.tar; docker run -d -e ROOT_URL=http://testci.bokuga.com -p 80:80 mazlix/testci" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You would need to update this with your IP addresses of your own servers.