Skip to content

Instantly share code, notes, and snippets.

@davetoxa
Last active October 25, 2019 08:03
Show Gist options
  • Save davetoxa/46c7ff2a3e690dfb7a46 to your computer and use it in GitHub Desktop.
Save davetoxa/46c7ff2a3e690dfb7a46 to your computer and use it in GitHub Desktop.
PLAY [all] ********************************************************************
GATHERING FACTS ***************************************************************
ok: [46.101.115.32]
TASK: [apt | update] **********************************************************
ok: [46.101.115.32]
TASK: [apt | install dependencies] ********************************************
changed: [46.101.115.32] => (item=build-essential,libssl-dev,libyaml-dev,libreadline6-dev,zlib1g-dev,libcurl4-openssl-dev,git,nginx,redis-server,postgresql,postgresql-contrib,libpq-dev,imagemagick,libmagickwand-dev,nodejs,htop)
TASK: [account | create] ******************************************************
changed: [46.101.115.32]
TASK: [account | copy authorized keys] ****************************************
changed: [46.101.115.32]
TASK: [account | copy ssh private key] ****************************************
changed: [46.101.115.32]
TASK: [account | copy ssh public key] *****************************************
changed: [46.101.115.32]
TASK: [rbenv | clone repo] ****************************************************
changed: [46.101.115.32]
TASK: [rbenv | check ruby-build installed] ************************************
failed: [46.101.115.32] => {"changed": true, "cmd": ["test", "-x", "/home/deploy/.rbenv/plugins/ruby-build"], "delta": "0:00:00.004754", "end": "2015-12-07 21:35:10.349957", "rc": 1, "start": "2015-12-07 21:35:10.345203", "warnings": []}
...ignoring
TASK: [rbenv | add bin to path] ***********************************************
changed: [46.101.115.32]
TASK: [rbenv | init] **********************************************************
changed: [46.101.115.32]
TASK: [rbenv | clone ruby-build repo] *****************************************
changed: [46.101.115.32]
TASK: [rbenv | check ruby {{ ruby_version }} installed] ***********************
failed: [46.101.115.32] => {"changed": true, "cmd": "RBENV_ROOT=/home/deploy/.rbenv PATH=\"$RBENV_ROOT/bin:$PATH\" rbenv versions | grep 2.2.3", "delta": "0:00:00.069096", "end": "2015-12-07 21:35:18.016313", "rc": 1, "start": "2015-12-07 21:35:17.947217", "warnings": []}
stderr: Warning: no Ruby detected on the system
...ignoring
TASK: [rbenv | install ruby {{ ruby_version }}] *******************************
changed: [46.101.115.32]
TASK: [rbenv | set global ruby {{ ruby_version }}] ****************************
changed: [46.101.115.32]
TASK: [rbenv | rehash] ********************************************************
changed: [46.101.115.32]
TASK: [rbenv | create .gemrc] *************************************************
changed: [46.101.115.32]
TASK: [ruby | install bundler] ************************************************
changed: [46.101.115.32]
TASK: [rbenv | change owner] **************************************************
changed: [46.101.115.32]
TASK: [postgresql | check user] ***********************************************
failed: [46.101.115.32] => {"changed": true, "cmd": "psql -U postgres -c \"\\copyright\"", "delta": "0:00:00.187702", "end": "2015-12-07 21:45:33.402497", "rc": 2, "start": "2015-12-07 21:45:33.214795", "warnings": []}
stderr: psql: FATAL: Peer authentication failed for user "postgres"
...ignoring
TASK: [postgresql | set auth type] ********************************************
changed: [46.101.115.32]
TASK: [postgresql | restart service] ******************************************
changed: [46.101.115.32]
TASK: [postgresql | create shared directory] **********************************
changed: [46.101.115.32]
TASK: [postgresql | copy database.yml] ****************************************
changed: [46.101.115.32]
TASK: [postgresql | create database] ******************************************
changed: [46.101.115.32]
TASK: [rails | copy settings.yml] *********************************************
changed: [46.101.115.32]
TASK: [nginx | check config] **************************************************
failed: [46.101.115.32] => {"changed": true, "cmd": ["test", "-f", "/etc/nginx/sites-enabled/davetoxa.conf"], "delta": "0:00:00.005054", "end": "2015-12-07 21:45:50.321347", "rc": 1, "start": "2015-12-07 21:45:50.316293", "warnings": []}
...ignoring
TASK: [nginx | createdir] *****************************************************
changed: [46.101.115.32]
TASK: [nginx | copy config] ***************************************************
changed: [46.101.115.32]
TASK: [nginx | restart service] ***********************************************
changed: [46.101.115.32]
PLAY RECAP ********************************************************************
46.101.115.32 : ok=30 changed=28 unreachable=0 failed=0
PLAY [all] *******************************************************************************************************************************
TASK [install python2] *******************************************************************************************************************
changed: [46.101.95.50]
TASK [apt | update] **********************************************************************************************************************
changed: [46.101.95.50]
TASK [apt | install dependencies] ********************************************************************************************************
ok: [46.101.95.50] => (item=[u'build-essential', u'libssl-dev', u'libyaml-dev', u'libreadline6-dev', u'zlib1g-dev', u'libcurl4-openssl-dev', u'git', u'nginx', u'redis-server', u'postgresql', u'postgresql-contrib', u'libpq-dev', u'imagemagick', u'libmagickwand-dev', u'nodejs', u'htop'])
TASK [account | create] ******************************************************************************************************************
ok: [46.101.95.50]
TASK [account | copy authorized keys] ****************************************************************************************************
[WARNING]: Consider using file module with state=directory rather than running mkdir
changed: [46.101.95.50]
TASK [account | copy ssh private key] ****************************************************************************************************
ok: [46.101.95.50]
TASK [account | copy ssh public key] *****************************************************************************************************
ok: [46.101.95.50]
TASK [rbenv | clone repo] ****************************************************************************************************************
ok: [46.101.95.50]
TASK [rbenv | check ruby-build installed] ************************************************************************************************
changed: [46.101.95.50]
TASK [rbenv | add bin to path] ***********************************************************************************************************
skipping: [46.101.95.50]
TASK [rbenv | init] **********************************************************************************************************************
skipping: [46.101.95.50]
TASK [rbenv | clone ruby-build repo] *****************************************************************************************************
skipping: [46.101.95.50]
TASK [rbenv | check ruby 2.4.2 installed] ************************************************************************************************
changed: [46.101.95.50]
TASK [rbenv | install ruby 2.4.2] ********************************************************************************************************
skipping: [46.101.95.50]
TASK [rbenv | set global ruby 2.4.2] *****************************************************************************************************
skipping: [46.101.95.50]
TASK [rbenv | rehash] ********************************************************************************************************************
skipping: [46.101.95.50]
TASK [rbenv | create .gemrc] *************************************************************************************************************
skipping: [46.101.95.50]
TASK [ruby | install bundler] ************************************************************************************************************
skipping: [46.101.95.50]
TASK [rbenv | change owner] **************************************************************************************************************
skipping: [46.101.95.50]
TASK [postgresql | check user] ***********************************************************************************************************
changed: [46.101.95.50]
TASK [postgresql | set auth type] ********************************************************************************************************
skipping: [46.101.95.50]
TASK [postgresql | restart service] ******************************************************************************************************
skipping: [46.101.95.50]
TASK [postgresql | create shared directory] **********************************************************************************************
skipping: [46.101.95.50]
TASK [postgresql | copy database.yml] ****************************************************************************************************
skipping: [46.101.95.50]
TASK [postgresql | create database] ******************************************************************************************************
skipping: [46.101.95.50]
TASK [nginx | check config] **************************************************************************************************************
changed: [46.101.95.50]
TASK [nginx | createdir] *****************************************************************************************************************
skipping: [46.101.95.50]
TASK [nginx | copy config] ***************************************************************************************************************
skipping: [46.101.95.50]
TASK [nginx | restart service] ***********************************************************************************************************
skipping: [46.101.95.50]
PLAY RECAP *******************************************************************************************************************************
46.101.95.50 : ok=12 changed=7 unreachable=0 failed=0
INFO [f11495e8] Running /usr/bin/env mkdir -p /tmp/davetoxa/ as [email protected]
INFO [f11495e8] Finished in 0.168 seconds with exit status 0 (successful).
INFO Uploading /tmp/davetoxa/git-ssh.sh 100.0%
INFO [5e5a1798] Running /usr/bin/env chmod +x /tmp/davetoxa/git-ssh.sh as [email protected]
INFO [5e5a1798] Finished in 0.170 seconds with exit status 0 (successful).
INFO [eec1c837] Running /usr/bin/env git ls-remote --heads [email protected]:davetoxa/davetoxa.git as [email protected]
INFO [eec1c837] Finished in 1.683 seconds with exit status 0 (successful).
INFO [424483a1] Running /usr/bin/env mkdir -p /home/deploy/applications/davetoxa/shared /home/deploy/applications/davetoxa/releases as [email protected]
INFO [424483a1] Finished in 0.173 seconds with exit status 0 (successful).
INFO [4119e7df] Running /usr/bin/env mkdir -p /home/deploy/applications/davetoxa/shared/bin /home/deploy/applications/davetoxa/shared/log /home/deploy/applications/davetoxa/shared/tmp/pids /home/deploy/applications/davetoxa/shared/tmp/cache /home/deploy/applications/davetoxa/shared/tmp/sockets /home/deploy/applications/davetoxa/shared/vendor/bundle /home/deploy/applications/davetoxa/shared/public/uploads /home/deploy/applications/davetoxa/shared/public/assets as [email protected]
INFO [4119e7df] Finished in 0.173 seconds with exit status 0 (successful).
INFO [a60684bc] Running /usr/bin/env mkdir -p /home/deploy/applications/davetoxa/shared/config /home/deploy/applications/davetoxa/shared/config as [email protected]
INFO [a60684bc] Finished in 0.166 seconds with exit status 0 (successful).
WARN puma.rb NOT FOUND!
INFO Uploading /home/deploy/applications/davetoxa/shared/puma.rb 100.0%
INFO puma.rb generated
INFO [c150e5ed] Running /usr/bin/env git clone --mirror [email protected]:davetoxa/davetoxa.git /home/deploy/applications/davetoxa/repo as [email protected]
INFO [c150e5ed] Finished in 2.269 seconds with exit status 0 (successful).
INFO [359728bc] Running /usr/bin/env git remote update as [email protected]
INFO [359728bc] Finished in 2.396 seconds with exit status 0 (successful).
INFO [df8d9146] Running /usr/bin/env mkdir -p /home/deploy/applications/davetoxa/releases/20151208025614 as [email protected]
INFO [df8d9146] Finished in 0.169 seconds with exit status 0 (successful).
INFO [fb428157] Running /usr/bin/env git archive master | tar -x -f - -C /home/deploy/applications/davetoxa/releases/20151208025614 as [email protected]
INFO [fb428157] Finished in 0.204 seconds with exit status 0 (successful).
INFO [054b769a] Running /usr/bin/env echo "2befb42" >> REVISION as [email protected]
INFO [054b769a] Finished in 0.167 seconds with exit status 0 (successful).
INFO [43184086] Running /usr/bin/env mkdir -p /home/deploy/applications/davetoxa/releases/20151208025614/config /home/deploy/applications/davetoxa/releases/20151208025614/config as [email protected]
INFO [43184086] Finished in 0.169 seconds with exit status 0 (successful).
INFO [47e7c44c] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/config/database.yml /home/deploy/applications/davetoxa/releases/20151208025614/config/database.yml as [email protected]
INFO [47e7c44c] Finished in 0.169 seconds with exit status 0 (successful).
INFO [f6c261dd] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/config/settings.yml /home/deploy/applications/davetoxa/releases/20151208025614/config/settings.yml as [email protected]
INFO [f6c261dd] Finished in 0.172 seconds with exit status 0 (successful).
INFO [be33756a] Running /usr/bin/env mkdir -p /home/deploy/applications/davetoxa/releases/20151208025614 /home/deploy/applications/davetoxa/releases/20151208025614 /home/deploy/applications/davetoxa/releases/20151208025614/tmp /home/deploy/applications/davetoxa/releases/20151208025614/tmp /home/deploy/applications/davetoxa/releases/20151208025614/tmp /home/deploy/applications/davetoxa/releases/20151208025614/vendor /home/deploy/applications/davetoxa/releases/20151208025614/public /home/deploy/applications/davetoxa/releases/20151208025614/public as [email protected]
INFO [be33756a] Finished in 0.169 seconds with exit status 0 (successful).
INFO [dbefa871] Running /usr/bin/env rm -rf /home/deploy/applications/davetoxa/releases/20151208025614/bin as [email protected]
INFO [dbefa871] Finished in 0.168 seconds with exit status 0 (successful).
INFO [e7563235] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/bin /home/deploy/applications/davetoxa/releases/20151208025614/bin as [email protected]
INFO [e7563235] Finished in 0.167 seconds with exit status 0 (successful).
INFO [e2266dd9] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/log /home/deploy/applications/davetoxa/releases/20151208025614/log as [email protected]
INFO [e2266dd9] Finished in 0.168 seconds with exit status 0 (successful).
INFO [9b796bf8] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/tmp/pids /home/deploy/applications/davetoxa/releases/20151208025614/tmp/pids as [email protected]
INFO [9b796bf8] Finished in 0.173 seconds with exit status 0 (successful).
INFO [73c303da] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/tmp/cache /home/deploy/applications/davetoxa/releases/20151208025614/tmp/cache as [email protected]
INFO [73c303da] Finished in 0.168 seconds with exit status 0 (successful).
INFO [61007dae] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/tmp/sockets /home/deploy/applications/davetoxa/releases/20151208025614/tmp/sockets as [email protected]
INFO [61007dae] Finished in 0.165 seconds with exit status 0 (successful).
INFO [31882269] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/vendor/bundle /home/deploy/applications/davetoxa/releases/20151208025614/vendor/bundle as [email protected]
INFO [31882269] Finished in 0.178 seconds with exit status 0 (successful).
INFO [0efe87d3] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/public/uploads /home/deploy/applications/davetoxa/releases/20151208025614/public/uploads as [email protected]
INFO [0efe87d3] Finished in 0.172 seconds with exit status 0 (successful).
INFO [2d4aed3c] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/shared/public/assets /home/deploy/applications/davetoxa/releases/20151208025614/public/assets as [email protected]
INFO [2d4aed3c] Finished in 0.166 seconds with exit status 0 (successful).
INFO [13f8d728] Running RBENV_ROOT=~/.rbenv RBENV_VERSION=2.2.3 ~/.rbenv/bin/rbenv exec bundle install --path /home/deploy/applications/davetoxa/shared/bundle --without development test --deployment --quiet as [email protected]
INFO [13f8d728] Finished in 191.494 seconds with exit status 0 (successful).
INFO [2cdca9ae] Running RBENV_ROOT=~/.rbenv RBENV_VERSION=2.2.3 ~/.rbenv/bin/rbenv exec bundle exec rake assets:precompile as [email protected]
INFO [2cdca9ae] Finished in 6.715 seconds with exit status 0 (successful).
INFO [fc8f822f] Running /usr/bin/env mkdir -p /home/deploy/applications/davetoxa/releases/20151208025614/assets_manifest_backup as [email protected]
INFO [fc8f822f] Finished in 0.182 seconds with exit status 0 (successful).
INFO [0a535f9d] Running /usr/bin/env cp /home/deploy/applications/davetoxa/releases/20151208025614/public/assets/manifest-08845ecf852d2dfbaab4cbbdda8b0595.json /home/deploy/applications/davetoxa/releases/20151208025614/assets_manifest_backup as [email protected]
INFO [0a535f9d] Finished in 0.166 seconds with exit status 0 (successful).
INFO [deploy:migrate] Run `rake db:migrate`
INFO [9b2d76f3] Running RBENV_ROOT=~/.rbenv RBENV_VERSION=2.2.3 ~/.rbenv/bin/rbenv exec bundle exec rake db:migrate as [email protected]
INFO [9b2d76f3] Finished in 3.467 seconds with exit status 0 (successful).
INFO [f2c17368] Running /usr/bin/env ln -s /home/deploy/applications/davetoxa/releases/20151208025614 /home/deploy/applications/davetoxa/releases/current as [email protected]
INFO [f2c17368] Finished in 0.165 seconds with exit status 0 (successful).
INFO [ca040516] Running /usr/bin/env mv /home/deploy/applications/davetoxa/releases/current /home/deploy/applications/davetoxa as [email protected]
INFO [ca040516] Finished in 0.168 seconds with exit status 0 (successful).
INFO [194c1d51] Running /usr/bin/env echo "Branch master (at 2befb42) deployed as release 20151208025614 by anton" >> /home/deploy/applications/davetoxa/revisions.log as [email protected]
INFO [194c1d51] Finished in 0.168 seconds with exit status 0 (successful).
INFO using conf file /home/deploy/applications/davetoxa/shared/puma.rb
INFO [98730896] Running RBENV_ROOT=~/.rbenv RBENV_VERSION=2.2.3 ~/.rbenv/bin/rbenv exec bundle exec puma -C /home/deploy/applications/davetoxa/shared/puma.rb --daemon as [email protected]
INFO [98730896] Finished in 3.963 seconds with exit status 0 (successful).
➜ davetoxa git:(master) ✗ 232s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment