Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
1 contributor

Users who have contributed to this file

26 lines (24 sloc) 985 Bytes
language: node_js
node_js:
- node
env:
- SERVER_IP_ADDRESS=138.68.163.126
before_install: # setup the RSA key for use in Dokku Deployment:
- openssl aes-256-cbc -K $encrypted_77965d5bdd4d_key -iv $encrypted_77965d5bdd4d_iv
-in deploy_key.enc -out ./deploy_key -d
- eval "$(ssh-agent -s)"
- chmod 600 ./deploy_key
- echo -e "Host $SERVER_IP_ADDRESS\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
- ssh-add ./deploy_key
# test ssh connection for: https://github.com/dwyl/learn-travis/issues/42
- ssh -i ./deploy_key root@138.68.163.126 pwd
after_success:
- npm install pm2 -g
# Use BASH instead of DASH! see: https://ubuntuforums.org/showthread.php?t=1932504
- ls -al /bin/sh && sudo rm /bin/sh && sudo ln -s /bin/bash /bin/sh && ls -al /bin/sh
# - if [ $TRAVIS_PULL_REQUEST_BRANCH ]; then
# sh .bin/deploy.sh;
# fi
# - sh ./bin/deploy.sh;
- pm2 deploy ecosystem.config.js production update
- pm2 deploy ecosystem.config.js production exec "pm2 reload all"
You can’t perform that action at this time.