Try self-hosted runner

This commit is contained in:
Siarhei Fedartsou 2024-06-25 20:27:17 +02:00
parent b82f87df1f
commit 47edf679b5

View File

@ -725,32 +725,32 @@ jobs:
make -C test/data make -C test/data
# we run benchmarks in tmpfs to avoid impact of disk IO # we run benchmarks in tmpfs to avoid impact of disk IO
- name: Create folder for tmpfs - name: Create folder for tmpfs
run: mkdir -p /opt/benchmarks run: mkdir -p ~/benchmarks_tmp
- name: Run PR Benchmarks - name: Run PR Benchmarks
run: | run: |
mount -t tmpfs -o size=4g none /opt/benchmarks mount -t tmpfs -o size=4g none ~/benchmarks_tmp
cp -rf pr/build /opt/benchmarks/build cp -rf pr/build ~/benchmarks_tmp/build
mkdir -p /opt/benchmarks/test mkdir -p ~/benchmarks_tmp/test
cp -rf pr/test/data /opt/benchmarks/test/data cp -rf pr/test/data ~/benchmarks_tmp/test/data
cp -rf pr/profiles /opt/benchmarks/profiles cp -rf pr/profiles ~/benchmarks_tmp/profiles
./pr/scripts/ci/run_benchmarks.sh -f /opt/benchmarks -r $(pwd)/pr_results -s $(pwd)/pr -b /opt/benchmarks/build -o ~/data.osm.pbf -g ~/gps_traces.csv ./pr/scripts/ci/run_benchmarks.sh -f ~/benchmarks_tmp -r $(pwd)/pr_results -s $(pwd)/pr -b ~/benchmarks_tmp/build -o ~/data.osm.pbf -g ~/gps_traces.csv
umount /opt/benchmarks umount ~/benchmarks_tmp
- name: Run Base Benchmarks - name: Run Base Benchmarks
run: | run: |
mount -t tmpfs -o size=4g none /opt/benchmarks mount -t tmpfs -o size=4g none ~/benchmarks_tmp
cp -rf base/build /opt/benchmarks/build cp -rf base/build ~/benchmarks_tmp/build
mkdir -p /opt/benchmarks/test mkdir -p ~/benchmarks_tmp/test
cp -rf base/test/data /opt/benchmarks/test/data cp -rf base/test/data ~/benchmarks_tmp/test/data
cp -rf base/profiles /opt/benchmarks/profiles cp -rf base/profiles ~/benchmarks_tmp/profiles
# TODO: remove it when base branch will have this file at needed location # TODO: remove it when base branch will have this file at needed location
if [ ! -f /opt/benchmarks/test/data/portugal_to_korea.json ]; then if [ ! -f ~/benchmarks_tmp/test/data/portugal_to_korea.json ]; then
cp base/src/benchmarks/portugal_to_korea.json /opt/benchmarks/test/data/portugal_to_korea.json cp base/src/benchmarks/portugal_to_korea.json ~/benchmarks_tmp/test/data/portugal_to_korea.json
fi fi
# we intentionally use scripts from PR branch to be able to update them and see results in the same PR # we intentionally use scripts from PR branch to be able to update them and see results in the same PR
./pr/scripts/ci/run_benchmarks.sh -f /opt/benchmarks -r $(pwd)/base_results -s $(pwd)/pr -b /opt/benchmarks/build -o ~/data.osm.pbf -g ~/gps_traces.csv ./pr/scripts/ci/run_benchmarks.sh -f ~/benchmarks_tmp -r $(pwd)/base_results -s $(pwd)/pr -b ~/benchmarks_tmp/build -o ~/data.osm.pbf -g ~/gps_traces.csv
umount /opt/benchmarks umount ~/benchmarks_tmp
- name: Post Benchmark Results - name: Post Benchmark Results
run: | run: |
python3 pr/scripts/ci/post_benchmark_results.py base_results pr_results python3 pr/scripts/ci/post_benchmark_results.py base_results pr_results