-
Notifications
You must be signed in to change notification settings - Fork 67
/
.gitlab-ci.yml
72 lines (63 loc) · 2.19 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
67
68
69
70
71
#variables:
# GIT_SUBMODULE_STRATEGY: recursive
default:
image: gitlab-icarous-base:latest
stages:
- build
- test
before_script:
- adduser myuser
- apt-get install -y ssh-client
- mkdir -p ~/.ssh
- echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config
- echo -e "$SWEE_SSHKEY" > ~/.ssh/id_rsa
- chmod 600 ~/.ssh/id_rsa
- chmod -R 777 /builds/larc-nia-fm/icarous
- cd /builds/larc-nia-fm/icarous
- git submodule update --init --recursive
- git clone [email protected]:larc-nia-fm/sirius.git --recurse-submodules
- git clone [email protected]:larc-nia-fm/polycarp.git
- mkdir -p /builds/larc-nia-fm/icarous/exe/cpu1/cf
- export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/builds/larc-nia-fm/icarous/Modules/lib
- export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/builds/larc-nia-fm/icarous/apps/rotorsim/QuadCopterSim
- export PYTHONPATH=$PYTHONPATH:/builds/larc-nia-fm/icarous/apps/rotorsim/QuadCopterSim
- export PYTHONPATH=$PYTHONPATH:/builds/larc-nia-fm/icarous/Python/pycarous
- export PYTHONPATH=$PYTHONPATH:/builds/larc-nia-fm/icarous/polycarp/Python
- export ICAROUS_HOME=/builds/larc-nia-fm/icarous
- pip3 install -r Python/pycarous/requirements.txt --upgrade
- cd sirius
#- make pipPkg
- make setenv
- source setenv.sh
- cd /builds/larc-nia-fm/icarous
build:
stage: build
script:
- sed -i s/#rotorsim/rotorsim/ Icarous_defs/apps.cmake
- sed -i s/#merger/merger/ Icarous_defs/apps.cmake
- sed -i s/#raft/raft/ Icarous_defs/apps.cmake
- sed -i s/#SBN/SBN/ Icarous_defs/apps.cmake
- sed -i s/#udp/udp/ Icarous_defs/apps.cmake
- sed -i s/#flarm/flarm/ Icarous_defs/apps.cmake
- sed -i s/#safe2ditch/safe2ditch/ Icarous_defs/apps.cmake
- make
- make install
artifacts:
when: always
paths:
- build/*
- exe/cpu1/*
- Modules/lib/*
expire_in: 2 days
test:
stage: test
script:
- chmod -R 777 /builds/larc-nia-fm/icarous
- sed -i s/arducopter/rotorsim/ Icarous_defs/apps.cmake
- cd sirius/Runner
- su myuser -c 'python3 RunScenarios.py ../scenarios/CITest/test_cases.yaml --test'
artifacts:
when: always
paths:
- sirius/Runner/sim_output/*
expire_in: 2 days