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
# we run benchmarks in tmpfs to avoid impact of disk IO
- name: Create folder for tmpfs
run: mkdir -p /opt/benchmarks
run: mkdir -p ~/benchmarks_tmp
- name: Run PR Benchmarks
run: |
mount -t tmpfs -o size=4g none /opt/benchmarks
cp -rf pr/build /opt/benchmarks/build
mkdir -p /opt/benchmarks/test
cp -rf pr/test/data /opt/benchmarks/test/data
cp -rf pr/profiles /opt/benchmarks/profiles
mount -t tmpfs -o size=4g none ~/benchmarks_tmp
cp -rf pr/build ~/benchmarks_tmp/build
mkdir -p ~/benchmarks_tmp/test
cp -rf pr/test/data ~/benchmarks_tmp/test/data
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
umount /opt/benchmarks
./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 ~/benchmarks_tmp
- name: Run Base Benchmarks
run: |
mount -t tmpfs -o size=4g none /opt/benchmarks
cp -rf base/build /opt/benchmarks/build
mkdir -p /opt/benchmarks/test
cp -rf base/test/data /opt/benchmarks/test/data
cp -rf base/profiles /opt/benchmarks/profiles
mount -t tmpfs -o size=4g none ~/benchmarks_tmp
cp -rf base/build ~/benchmarks_tmp/build
mkdir -p ~/benchmarks_tmp/test
cp -rf base/test/data ~/benchmarks_tmp/test/data
cp -rf base/profiles ~/benchmarks_tmp/profiles
# TODO: remove it when base branch will have this file at needed location
if [ ! -f /opt/benchmarks/test/data/portugal_to_korea.json ]; then
cp base/src/benchmarks/portugal_to_korea.json /opt/benchmarks/test/data/portugal_to_korea.json
if [ ! -f ~/benchmarks_tmp/test/data/portugal_to_korea.json ]; then
cp base/src/benchmarks/portugal_to_korea.json ~/benchmarks_tmp/test/data/portugal_to_korea.json
fi
# 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
umount /opt/benchmarks
./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 ~/benchmarks_tmp
- name: Post Benchmark Results
run: |
python3 pr/scripts/ci/post_benchmark_results.py base_results pr_results