From 46fafdff3d2e7ffe657ba62cfb3a758fb9053da1 Mon Sep 17 00:00:00 2001 From: Pulse Monitor Date: Mon, 4 Aug 2025 08:20:01 +0000 Subject: [PATCH] feat: implement multi-architecture release strategy - Updated build-release.sh to create universal tarball with all architectures - Use pulse-wrapper.sh as main executable that auto-detects architecture - Wrapper automatically cleans up unused architecture binaries - Single tarball works for amd64, arm64, and armv7 - Compatible with Proxmox helper script expectations --- VERSION | 2 +- build-release.sh | 8 ++++++-- pulse-wrapper.sh | 3 +++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/VERSION b/VERSION index f5eaf8d6b..166b27a38 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -4.0.0-rc.1-test +4.0.0-test diff --git a/build-release.sh b/build-release.sh index b5a7e659d..c3de0985f 100755 --- a/build-release.sh +++ b/build-release.sh @@ -52,8 +52,10 @@ for build_name in "${!builds[@]}"; do # Copy files cp "$BUILD_DIR/pulse-$build_name" "$staging_dir/pulse" + mkdir -p "$staging_dir/frontend-modern" cp -r frontend-modern/dist "$staging_dir/frontend-modern/" - cp README.md LICENSE pulse.service install.sh "$staging_dir/" + cp README.md LICENSE install.sh "$staging_dir/" + # Note: pulse.service might not exist in Go version # Create tarball cd "$staging_dir" @@ -86,8 +88,10 @@ for build_name in "${!builds[@]}"; do done # Copy common files +mkdir -p "$universal_staging/frontend-modern" cp -r frontend-modern/dist "$universal_staging/frontend-modern/" -cp README.md LICENSE pulse.service install.sh pulse-wrapper.sh "$universal_staging/" +cp README.md LICENSE install.sh pulse-wrapper.sh "$universal_staging/" +echo "$VERSION" > "$universal_staging/VERSION" # Rename wrapper to 'pulse' for seamless usage cp pulse-wrapper.sh "$universal_staging/pulse" diff --git a/pulse-wrapper.sh b/pulse-wrapper.sh index d5c59fc65..2c364b9e8 100755 --- a/pulse-wrapper.sh +++ b/pulse-wrapper.sh @@ -30,6 +30,9 @@ if [ ! -f "$SCRIPT_DIR/$BINARY" ]; then exit 1 fi +# Make the correct binary executable (in case permissions were lost) +chmod +x "$SCRIPT_DIR/$BINARY" 2>/dev/null || true + # On first run, clean up other architecture binaries to save space if [ -f "$SCRIPT_DIR/.first-run-cleanup" ]; then echo "Cleaning up unused architecture binaries..."