Fakultas Ilmu Komputer UI

Commit a13a6f7e authored by Hafiyyan's avatar Hafiyyan
Browse files

GCP Deployment

parent aa3fccb4
Pipeline #26611 passed with stages
in 13 minutes and 6 seconds
......@@ -78,17 +78,16 @@ staging:
production:
stage: deploy
script:
- apt-get update -qy
- apt-get install sshpass
- git clone https://gitlab.com/PPL2017csui/PPLA1.git
- cd PPLA1
- git checkout master
- git pull
- git remote add deployment ssh://kape@bot.recruit.id:8022/home/kape.git
- mkdir ~/.ssh
- echo -e "Host bot.recruit.id\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
- sshpass -p yukcarikape git push deployment master:master --force
when: manual
- 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
- eval $(ssh-agent -s)
- ssh-add <(echo "$KEY_DEPLOYMENT")
- mkdir -p ~/.ssh
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
- ssh-keyscan -t rsa 10.119.234.71 >> ~/.ssh/known_hosts
- ssh hafiyyan94_gmail_com@35.240.226.230 'sudo bash /home/hafiyyan94_gmail_com/deployment.sh'
environment:
name: production_gcp
url: $PRODUCTION_GCP
only:
- master
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment