Browse Source

ssh config in deployment

pull/2/head
Levi Olson 6 years ago
parent
commit
f0b60a4193
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      .gitlab-ci.yml

+ 1
- 0
.gitlab-ci.yml View File

@ -28,6 +28,7 @@ deploy_prod:
- npm install - npm install
- sshpass -V - sshpass -V
- export SSHPASS=$SSH_PASS - export SSHPASS=$SSH_PASS
- mkdir ~/.ssh
- echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config - echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config
- sshpass -e ssh root@45.55.44.195 "cd /home/forge/leviolson-website && git pull && bash -c \"pm2 stop LeviOlson.com && pm2 delete LeviOlson.com && pm2 start app.js --name LeviOlson.com && pm2 logs --nostream --lines 2 LeviOlson.com && exit 0\" && exit 0" - sshpass -e ssh root@45.55.44.195 "cd /home/forge/leviolson-website && git pull && bash -c \"pm2 stop LeviOlson.com && pm2 delete LeviOlson.com && pm2 start app.js --name LeviOlson.com && pm2 logs --nostream --lines 2 LeviOlson.com && exit 0\" && exit 0"
environment: environment:

Loading…
Cancel
Save