11name : Build
22
3- # on:
4- # push:
5- # branches:
6- # - main
3+ on :
4+ push :
5+ branches :
6+ - main
77
88jobs :
99 run-tests-and-examples :
@@ -19,63 +19,76 @@ jobs:
1919 python-version : ${{ matrix.python-version }}
2020 - name : Install wrench-daemon
2121 run : |
22- cd /tmp/
23- pip install jsonref
24- sudo apt-get update
25- sudo apt-get -y install gcc
26- sudo apt-get -y install libasio-dev
27- sudo apt-get -y install libboost-all-dev
28- wget https://github.com/nlohmann/json/archive/refs/tags/v3.10.5.tar.gz
29- tar -xf v3.10.5.tar.gz
30- cd json-3.10.5
31- cmake .
32- make -j4
33- sudo make install
34- cd ..
35- wget --no-check-certificate https://framagit.org/simgrid/simgrid/-/archive/v3.36/simgrid-v3.36.tar.gz
36- tar -xf simgrid-v3.36.tar.gz
37- cd simgrid-v3.36
38- cmake -Denable_documentation=OFF .
39- make -j4
40- sudo make install
41- cd ..
42- git clone https://github.com/wrench-project/wrench.git
43- cd wrench
44- cmake .
45- make -j4 wrench-daemon
46- sudo make install
47- cd ..
48- cd
49- # WITH DOCKER BELOW
50- #curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
51- #sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
22+ # WITHOUT DOCKER
23+ #cd /tmp/
24+ #pip install jsonref
5225 #sudo apt-get update
53- #sudo apt-get install -y docker-ce docker-ce-cli containerd.io
54- #docker pull wrenchproject/wrench:unstable
26+ #sudo apt-get -y install gcc
27+ #sudo apt-get -y install libasio-dev
28+ #sudo apt-get -y install libboost-all-dev
29+ #wget https://github.com/nlohmann/json/archive/refs/tags/v3.10.5.tar.gz
30+ #tar -xf v3.10.5.tar.gz
31+ #cd json-3.10.5
32+ #cmake .
33+ #make -j4
34+ #sudo make install
35+ #cd ..
36+ #wget --no-check-certificate https://framagit.org/simgrid/simgrid/-/archive/v3.36/simgrid-v3.36.tar.gz
37+ #tar -xf simgrid-v3.36.tar.gz
38+ #cd simgrid-v3.36
39+ #cmake -Denable_documentation=OFF .
40+ #make -j4
41+ #sudo make install
42+ #cd ..
43+ #git clone https://github.com/wrench-project/wrench.git
44+ #cd wrench
45+ #cmake .
46+ #make -j4 wrench-daemon
47+ #sudo make install
48+ #cd ..
49+ #cd
50+ # END WITHOUT DOCKER
51+ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
52+ sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
53+ sudo apt-get update
54+ sudo apt-get install -y docker-ce docker-ce-cli containerd.io
55+ docker pull wrenchproject/wrench:unstable
5556 - name : Start wrench-daemon
5657 run : |
57- export LD_LIBRARY_PATH=/usr/local/lib/
58- wrench-daemon &
59- #docker run -p 8101:8101 wrenchproject/wrench:unstable wrench-daemon &
60- echo "PID=$!" >> $GITHUB_ENV
58+ # WITHOUT DOCKER
59+ #export LD_LIBRARY_PATH=/usr/local/lib/
60+ #wrench-daemon &
61+ #echo "PID=$!" >> $GITHUB_ENV
62+ # END WITHOUT DOCKER
63+ docker run --name wrench-daemon-container -v `pwd`:/home/wrench wrenchproject/wrench:unstable wrench-daemon &
6164 - name : Install the wrench Python API
6265 run : |
63- pip install .
66+ # WIThOUT DOCKER
67+ #pip install .
68+ # END WITHOUT DOCKER
69+ docker exec --workdir /home/wrench/ wrench-daemon-container sudo pip install .
6470 - name : Run all tests
6571 run : |
66- echo `pwd`
67- echo `ls`
68- cd tests
69- bash ./run_all_tests.sh
70- cd ..
72+ # WITHOUT DOCKER
73+ #cd tests
74+ #bash ./run_all_tests.sh
75+ #cd ..
76+ # END WITHOUT DOCKER
77+ docker exec --workdir /home/wrench/tests wrench-daemon-container bash ./run_all_tests.sh
7178 - name : Run all examples
7279 run : |
73- cd examples
74- bash ./run_all_examples.sh
75- cd ..
80+ # WITHOUT DOCKER
81+ #cd examples
82+ #bash ./run_all_examples.sh
83+ #cd ..
84+ # END WITHOUT DOCKER
85+ docker exec --workdir /home/wrench/examples wrench-daemon-container bash ./run_all_examples.sh
7686 - name : Kill wrench-daemon
7787 run : |
78- kill ${{ env.PID }} || true
88+ # WITHOUT DOCKER
89+ #kill ${{ env.PID }} || true
90+ # END WITHOUT DOCKER
91+ docker kill wrench-daemon-container
7992 build-documentation :
8093 runs-on : ubuntu-latest
8194 strategy :
0 commit comments