Pre-seed BRouter volume in CI instead of bind mount override
The bind mount override (docker-compose.ci.yml) failed because file permissions on the cached segment prevented the entrypoint from seeing the file, causing a fresh download on every CI run. Instead: create the named volume and copy the cached segment into it before compose starts, using alpine with explicit chmod. The entrypoint then finds the segment and skips the download, so BRouter starts in ~4s instead of ~2min. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
bea391c9fd
commit
1dcc518242
2 changed files with 9 additions and 5 deletions
10
.github/workflows/ci.yml
vendored
10
.github/workflows/ci.yml
vendored
|
|
@ -204,8 +204,16 @@ jobs:
|
|||
mkdir -p /tmp/brouter-segments
|
||||
wget -q "https://brouter.de/brouter/segments4/E10_N50.rd5" -O /tmp/brouter-segments/E10_N50.rd5
|
||||
|
||||
- name: Pre-seed BRouter segment volume
|
||||
run: |
|
||||
docker volume create trails_brouter_segments
|
||||
docker run --rm \
|
||||
-v /tmp/brouter-segments:/src:ro \
|
||||
-v trails_brouter_segments:/dst \
|
||||
alpine sh -c "cp /src/*.rd5 /dst/ && chmod a+r /dst/*.rd5"
|
||||
|
||||
- name: Start services
|
||||
run: docker compose -f docker-compose.dev.yml -f docker-compose.ci.yml up -d --wait --build
|
||||
run: docker compose -f docker-compose.dev.yml up -d --wait --build
|
||||
env:
|
||||
BROUTER_URL: http://localhost:17777
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +0,0 @@
|
|||
services:
|
||||
brouter:
|
||||
volumes:
|
||||
- /tmp/brouter-segments:/data/segments
|
||||
Loading…
Add table
Add a link
Reference in a new issue