-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.gitlab-ci.yml
67 lines (60 loc) · 1.7 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
image: conanio/gcc9:latest
stages:
- build
- test
- deploy
build_client:
stage: build
script:
- ls
- mkdir build
- cd build
- conan remote add bincrafters https://api.bintray.com/conan/bincrafters/public-conan
- conan remote add epitech https://api.bintray.com/conan/epitech/public-conan
- sudo apt-get update && yes | sudo apt-get install --yes --force-yes --assume-yes qtdeclarative5-dev jackd
- conan install ..
- cmake ..
- make babel-client
build_server:
stage: build
script:
- ls
- mkdir build
- cd build
- conan remote add bincrafters https://api.bintray.com/conan/bincrafters/public-conan
- conan remote add epitech https://api.bintray.com/conan/epitech/public-conan
- sudo apt-get update && yes | sudo apt-get install --yes --force-yes --assume-yes qtdeclarative5-dev jackd
- conan install ..
- cmake ..
- make babel-server
test_client:
stage: test
allow_failure: true
dependencies:
- build_client
script:
- make babel-client-test
- ./babel-client-test
test_server:
stage: test
allow_failure: true
dependencies:
- build_server
script:
- make babel-server-test
- ./babel-server-test
full_deploy:
stage: deploy
only:
- master
script:
- echo "Pushing to $TARGET_REPO"
- mkdir -p ~/.ssh
- echo "$SSH_PRIVATE_KEY" > ~/.ssh/epitech
- chmod 600 ~/.ssh/epitech
- git config core.sshCommand "ssh -o \"StrictHostKeyChecking=no\" -i ~/.ssh/epitech -F /dev/null"
- git remote remove epitech || true
- git remote add epitech $TARGET_REPO || true
- git push epitech HEAD:$CI_COMMIT_REF_NAME
- git config --unset core.sshCommand
- rm -rf ~/.ssh/epitech