fix(ci): persist PUB_CACHE across woodpecker steps

Each step runs in a fresh container from the builder image, so the
default /root/.pub-cache doesn't survive from `flutter pub get` into
the codegen/build steps. Point PUB_CACHE at a workspace-local path
instead, which is shared across steps.
This commit is contained in:
2026-09-03 17:23:23 +02:00
parent eddfe52a51
commit 4dbe0b71e6

View File

@@ -19,20 +19,27 @@ steps:
- echo "$UPLOAD_KEYSTORE_B64" | base64 -d > secrets/upload-keystore.jks
- echo "$KEYSTORE_PROPERTIES_B64" | base64 -d > secrets/keystore.properties
# Each step runs in a fresh container from the builder image -- only the
# workspace volume is shared between them. Pointing PUB_CACHE at a
# workspace-local dir (instead of the image's default /root/.pub-cache)
# is what lets `flutter pub get`'s downloads survive into later steps.
- name: dependencies
image: git.firka.app/firka/firka-builder:latest
commands:
- export PUB_CACHE="$CI_WORKSPACE/.pub-cache"
- cd firka
- flutter pub get
- name: codegen
image: git.firka.app/firka/firka-builder:latest
commands:
- export PUB_CACHE="$CI_WORKSPACE/.pub-cache"
- cd firka
- dart run scripts/codegen.dart
- name: build
image: git.firka.app/firka/firka-builder:latest
commands:
- export PUB_CACHE="$CI_WORKSPACE/.pub-cache"
- cd firka
- flutter build apk --release