Fakultas Ilmu Komputer UI

.gitlab-ci.yml 1.16 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
#test:
#  script:
#  - apt-get update -qy
#  - apt-get install -y python-dev python-pip sudo postgresql postgresql-client libpq-dev
#  - service postgresql start
#  - sudo -u postgres psql -c "CREATE USER kape WITH PASSWORD 'kape' CREATEDB"
#  - sudo -u postgres psql -c "CREATE DATABASE kape OWNER kape"
#  - pip install -r requirements.txt
#  - python manage.py migrate
#  - python manage.py test
Zamil Majdy's avatar
Zamil Majdy committed
11
12
13
14
15

staging:
  type: deploy
  script:
  - apt-get update -qy
16
  - apt-get install sshpass
17
18
19
20
  - git clone https://gitlab.com/PPL2017csui/PPLA1.git
  - cd PPLA1
  - git checkout UserStory1
  - git pull
Zamil Majdy's avatar
Zamil Majdy committed
21
  - git remote add deployment ssh://kape@bot.recruit.id:8022/home/kape.git
22
23
24
  - sshpass -p yukcarikape git push deployment UserStory1:master --force
  - cd ..
  - sshpass -p yukcarikape git push deployment UserStory1:master --force
25
  only:
26
   - UserStory1
Zamil Majdy's avatar
Zamil Majdy committed
27
28
29
30
31

production:
  type: deploy
  script:
  - apt-get update -qy
32
  - apt-get install sshpass
33
34
35
  - git clone https://gitlab.com/PPL2017csui/PPLA1.git
  - cd PPLA1
  - git checkout master
Zamil Majdy's avatar
Zamil Majdy committed
36
  - git remote add deployment ssh://kape@bot.recruit.id:8022/home/kape.git
37
  - sshpass -p yukcarikape git push deployment master:master --force
Zamil Majdy's avatar
Zamil Majdy committed
38
39
  only:
  - master