name: Release on: push: tags: ['v*'] permissions: contents: write packages: write jobs: # GNOME/KDE Wayland engine: libei >= 1.1 first ships in Ubuntu 24.04, so this plugin needs # glibc >= 2.39. It is only loaded on portal sessions; X11 and wlroots hosts never open it. portal-plugin: strategy: matrix: include: - { arch: x86_64, runner: ubuntu-24.04 } - { arch: aarch64, runner: ubuntu-24.04-arm } runs-on: ${{ matrix.runner }} steps: - uses: actions/checkout@v4 - name: Install build dependencies run: | sudo apt-get update sudo apt-get install -y build-essential pkg-config \ libx11-dev libxext-dev libxtst-dev libxfixes-dev libglib2.0-dev libpipewire-0.3-dev libei-dev - uses: dtolnay/rust-toolchain@stable - run: UU_NO_GTK=1 cargo build --release --locked --features portal,engine-plugins --bin uuremote-server - uses: actions/upload-artifact@v4 with: name: libuu-portal-${{ matrix.arch }} path: target/release/libuu-portal.so build: needs: portal-plugin strategy: matrix: include: - { arch: x86_64, runner: ubuntu-22.04 } - { arch: aarch64, runner: ubuntu-22.04-arm } # Built on 22.04 so the binary also runs on Ubuntu 22.04/24.04 and newer Debian (glibc >= 2.35). runs-on: ${{ matrix.runner }} steps: - uses: actions/checkout@v4 - name: Install build dependencies run: | sudo apt-get update sudo apt-get install -y build-essential pkg-config \ libx11-dev libxext-dev libxtst-dev libxfixes-dev libgtk-3-dev libsdl2-dev \ libwayland-dev libwayland-bin libxkbcommon-dev - uses: dtolnay/rust-toolchain@stable - run: cargo test --release --locked # One package for every desktop: Wayland (wlroots) and GNOME/KDE portal engines are plugins # opened at runtime (engine-plugins), so X11 hosts need none of their libraries. - run: cargo build --release --locked --features wayland,portal,engine-plugins - uses: actions/download-artifact@v4 with: name: libuu-portal-${{ matrix.arch }} path: target/release # Experimental viewer; built after the host so uuremote-server keeps the release features. - run: cargo build --release --locked --features native-viewer,viewer-sdl --bin uuremote-viewer - name: Package run: | name=uu-remote-linux-${GITHUB_REF_NAME}-${{ matrix.arch }}-linux mkdir -p "$name" cp target/release/uuremote-server target/release/uuremote-viewer target/release/libuu-wayland.so target/release/libuu-portal.so \ LICENSE README.md README.en.md config.example.json "$name/" cp -r contrib "$name/" tar czf "$name.tar.gz" "$name" sha256sum "$name.tar.gz" > "$name.tar.gz.sha256" - uses: actions/upload-artifact@v4 with: name: package-${{ matrix.arch }} path: uu-remote-linux-*.tar.gz* # One publisher, so the matrix legs never race to create the release. release: needs: build runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 - uses: actions/download-artifact@v4 with: pattern: package-* merge-multiple: true - uses: softprops/action-gh-release@v2 with: body_path: docs/release-notes/${{ github.ref_name }}.md files: | uu-remote-linux-*.tar.gz uu-remote-linux-*.tar.gz.sha256 # Headless NAS image (docker/), built from the release tarball published by the job above. docker: needs: release runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 - uses: docker/login-action@v3 with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - uses: docker/build-push-action@v6 with: context: docker build-args: VERSION=${{ github.ref_name }} push: true tags: | ghcr.io/vallierdev/uu-remote-linux:${{ github.ref_name }} ghcr.io/vallierdev/uu-remote-linux:latest