chore: Update Makefile to skip PKG_HASH and comment out PKG_MIRROR_HASH #44
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build FusionTunX Packages | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| tag_name: | |
| description: 'Release Tag' | |
| required: true | |
| default: 'v1.0.0' | |
| publish: | |
| description: 'Publish to Release?' | |
| type: boolean | |
| required: true | |
| default: true | |
| push: | |
| branches: | |
| - main | |
| - dev | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| build_packages: | |
| name: Build Debian/Ubuntu & Arch Linux Packages | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| - name: Install Dependencies | |
| run: sudo apt-get update && sudo apt-get install -y make wget curl unzip tar binutils zstd golang nodejs npm | |
| - name: Install Swag (Swagger Generator) | |
| run: | | |
| go install github.com/swaggo/swag/cmd/swag@latest | |
| echo "$HOME/go/bin" >> $GITHUB_PATH | |
| - name: Build All Packages (Debian + Arch) | |
| run: make build-all | |
| - name: Upload Debian Packages | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: fusiontunx-deb | |
| path: build/*.deb | |
| - name: Upload Arch Linux Packages | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: fusiontunx-arch | |
| path: build/*.pkg.tar.zst | |
| - name: Upload All Core Binaries | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: fusiontunx-core-binaries | |
| path: src/bin/**/* | |
| build_openwrt: | |
| permissions: | |
| contents: write | |
| name: Build OpenWrt ${{ matrix.arch }}-${{ matrix.branch }} | |
| runs-on: ubuntu-latest | |
| continue-on-error: true | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| branch: | |
| - openwrt-24.10 | |
| - openwrt-25.12 | |
| arch: | |
| - x86_64 | |
| - i386_pentium-mmx | |
| - aarch64_cortex-a53 | |
| - aarch64_cortex-a72 | |
| - aarch64_generic | |
| - arm_cortex-a15_neon-vfpv4 | |
| - arm_cortex-a9 | |
| - arm_cortex-a7 | |
| - mips_24kc | |
| - mipsel_74kc | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Feed Structure | |
| run: | | |
| mkdir -p feeds/fusiontunx | |
| mkdir -p feeds/luci-app-fusiontunx | |
| cp -f openwrt/fusiontunx/Makefile feeds/fusiontunx/ | |
| cp -rf files feeds/fusiontunx/ | |
| cp -rf openwrt/luci-app-fusiontunx/* feeds/luci-app-fusiontunx/ | |
| - name: Build Package | |
| uses: openwrt/gh-action-sdk@main | |
| env: | |
| ARCH: ${{ matrix.arch }}-${{ matrix.branch }} | |
| FEEDNAME: fusiontunx | |
| PACKAGES: ${{ matrix.arch == 'x86_64' && 'fusiontunx luci-app-fusiontunx' || 'fusiontunx' }} | |
| INDEX: 1 | |
| NO_SHFMT_CHECK: 1 | |
| KEY_BUILD: ${{ secrets.SIGNING_KEY_SEC }} | |
| # V: s | |
| - name: Organize Artifacts | |
| run: | | |
| mkdir -p output | |
| if [[ "${{ matrix.branch }}" == "openwrt-24.10" ]]; then | |
| # OpenWrt 24.10 uses IPK | |
| find bin/packages -name "fusiontunx_*.ipk" -exec cp {} output/ \; | |
| find bin/packages -name "luci-app-fusiontunx_*.ipk" -exec cp {} output/ \; | |
| else | |
| # OpenWrt 25.12 uses APK | |
| find bin/packages -name "fusiontunx-*.apk" ! -name "luci-app-*" -exec sh -c 'cp "$1" "output/fusiontunx-${{ matrix.arch }}.apk"' sh {} \; | |
| find bin/packages -name "luci-app-fusiontunx-*.apk" -exec cp {} output/ \; | |
| fi | |
| - name: Upload Artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: fusiontunx-openwrt-${{ matrix.arch }}-${{ matrix.branch }} | |
| path: output/* | |
| aggregate_packages: | |
| needs: [build_packages, build_openwrt] | |
| if: ${{ !cancelled() }} | |
| name: Aggregate All Packages | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Download OpenWrt Artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| pattern: fusiontunx-openwrt-* | |
| path: downloaded/openwrt | |
| merge-multiple: true | |
| - name: Download Debian Artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: fusiontunx-deb | |
| path: downloaded/debian | |
| - name: Download Arch Linux Artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: fusiontunx-arch | |
| path: downloaded/arch | |
| - name: Download Core Binaries | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: fusiontunx-core-binaries | |
| path: downloaded/core | |
| - name: List All Files | |
| run: ls -R downloaded | |
| - name: Upload Combined Artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: fusiontunx-all-packages | |
| path: downloaded/**/* | |
| - name: Create Release and Upload Assets | |
| uses: softprops/action-gh-release@v1 | |
| if: ${{ inputs.publish == true }} | |
| with: | |
| tag_name: ${{ inputs.tag_name }} | |
| body: | | |
| # FusionTunX Release ${{ inputs.tag_name }} | |
| This release contains pre-built packages for OpenWrt, Debian/Ubuntu, Arch Linux, and standalone core binaries. | |
| ## Package Details | |
| - **OpenWrt**: `.ipk` (24.10) and `.apk` (25.12) packages | |
| - **Debian/Ubuntu**: `.deb` packages for `amd64`, `arm64`, `armhf` | |
| - **Arch Linux**: `.pkg.tar.zst` packages for `x86_64`, `aarch64`, `armv7h` | |
| - **Core Binaries**: Standalone binaries for all architectures (useful for other Linux distros) | |
| See [README](https://github.com/${{ github.repository }}) for full documentation. | |
| files: downloaded/**/* | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |