New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Travis deploy setup #42

Merged
merged 1 commit into from Aug 16, 2017
File filter...
Filter file types
Jump to file or symbol
Failed to load files and symbols.
+21 −0
Diff settings

Always

Just for now

Copy path View file
@@ -0,0 +1,11 @@
script:
- if [[ "$TRAVIS_BRANCH" = "master" && "$TRAVIS_EVENT_TYPE" = "push" ]]; then
openssl aes-256-cbc -K $encrypted_a641d77e729e_key -iv $encrypted_a641d77e729e_iv
-in deploy/deploy_rsa.enc -out /tmp/deploy_rsa -d;

eval "$(ssh-agent -s)";
chmod 600 /tmp/deploy_rsa;
ssh-add /tmp/deploy_rsa;

ssh -o StrictHostKeyChecking=no root@$RUNNER_HOST "tsp git -C ./ruby-bench-docker pull --rebase origin master && tsp ./ruby-bench-docker/deploy/script";

This comment has been minimized.

@bmarkons

bmarkons Aug 15, 2017

Collaborator

Deploy is also queued as tsp task.

This comment has been minimized.

@tgxworld

tgxworld Aug 16, 2017

Member

Which server is this being built on?

This comment has been minimized.

@bmarkons

bmarkons Aug 16, 2017

Collaborator

Bare metal - where suites are being run.

I am not doing push to docker hub, just pulling latest changes and rebuilding images.

This comment has been minimized.

@tgxworld

tgxworld Aug 16, 2017

Member

Hmm better to build this on the web server. The bare metal server might be running benchmarks and building can be CPU intensive affecting the results

This comment has been minimized.

@bmarkons

bmarkons Aug 17, 2017

Collaborator

The bare metal server might be running benchmarks and building can be CPU intensive affecting the results

For that reason I enqueue deploy task through tcp, to ensure no suite is running when deploy is in progress. Have a look at this line we are commenting on ⬆️

This comment has been minimized.

@bmarkons

bmarkons Aug 17, 2017

Collaborator

better to build this on the web server

I am building images on bare metal server since that's where they are being used. We don't need docker images on web server.

The alternative way would be to build those on Travis and push them to docker hub.

This comment has been minimized.

@tgxworld

tgxworld Aug 17, 2017

Member

Yea lets build on Travis instead even though it might be slower. We should try and keep the bare-metal free from running any other services except fro benchmarks.

fi
Copy path View file
BIN +3.17 KB deploy/deploy_rsa.enc
Binary file not shown.
Copy path View file
@@ -0,0 +1,10 @@
#!/bin/sh

cd $HOME/ruby-bench-docker/rails/master
docker-compose build

cd $HOME/ruby-bench-docker/sequel/master
docker-compose build

cd $HOME/ruby-bench-docker/pg/
docker-compose build
ProTip! Use n and p to navigate between commits in a pull request.