Private
Public Access
1
0

fix: Alpine build - truncated YAML and wrong abuild output path

Root causes of ALL Alpine build failures:
1. ci.yml: Verify Alpine package step was TRUNCATED at line 339 -
   missing closing quote, then clause, fi, and entire upload step.
   This caused YAML parse failure every run.
2. build-alpine.sh: Copy path was /home/builduser/packages/home/x86_64/
   but abuild outputs to /home/builduser/packages/builduser/x86_64/.
   The find fallback caught stale packages from previous builds.

Fixes:
- Complete the Verify Alpine package step with proper if/fi
- Add Upload to Gitea Release step for Alpine (was completely missing)
- Fix abuild output path in build-alpine.sh
This commit is contained in:
2026-05-27 22:01:19 -05:00
parent 904654212f
commit 2f73237fd6
2 changed files with 20 additions and 2 deletions

View File

@ -336,7 +336,24 @@ jobs:
echo "Expected version: $EXPECTED_VERSION"
echo "Package file: $FILE"
# Verify filename contains expected version
if ! echo "$FILE" | grep -q "$EXPECTED_VERSION
if ! echo "$FILE" | grep -q "$EXPECTED_VERSION"; then
echo "ERROR: Alpine package version ($FILE) does not match expected version ($EXPECTED_VERSION)!"
exit 1
fi
echo "Alpine package verification passed"
- name: Upload to Gitea Release
if: startsWith(github.ref, 'refs/tags/')
env:
GITEA_TOKEN: ${{ secrets.GITEATOKEN }}
run: |
TAG_NAME=${GITHUB_REF#refs/tags/}
FILE=$(ls releases/linux-patch-api-*.apk 2>/dev/null | head -1)
if [ -z "$FILE" ]; then
echo "ERROR: No Alpine package found for upload!"
exit 1
fi
chmod +x scripts/upload-release.sh
./scripts/upload-release.sh "$TAG_NAME" "$FILE"
build-arch:
name: Build Arch Package

View File

@ -147,8 +147,9 @@ if [ "$(id -u)" = "0" ]; then
su - builduser -c "cd $WORKSPACE_DIR && abuild checksum && abuild -d"
# Copy APK from builduser packages to releases
# Note: abuild outputs to /home/builduser/packages/builduser/x86_64/ not /home/builduser/packages/home/x86_64/
mkdir -p releases
cp /home/builduser/packages/home/x86_64/*.apk releases/ 2>/dev/null || find /home/builduser/packages -name "*.apk" -exec cp {} releases/ \; 2>/dev/null || true
cp /home/builduser/packages/builduser/x86_64/*.apk releases/ 2>/dev/null || find /home/builduser/packages -name "*.apk" -exec cp {} releases/ \; 2>/dev/null || true
else
cd "$WORKSPACE_DIR"
abuild checksum