From be204fc69aa9d9c4e64e5f105fbdce65ce73adcb Mon Sep 17 00:00:00 2001 From: Christopher Kolstad Date: Mon, 15 Jan 2024 11:11:07 +0100 Subject: [PATCH] Updated to cargo-dist 0.7.1 (#382) --- .github/workflows/release.yml | 12 +- Cargo.toml | 7 +- server/Cargo.toml | 6 + server/wix/main.wxs | 228 ++++++++++++++++++++++++++++++++++ 4 files changed, 245 insertions(+), 8 deletions(-) create mode 100644 server/wix/main.wxs diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index cf7d70bc..7aa8f009 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -59,7 +59,9 @@ jobs: with: submodules: recursive - name: Install cargo-dist - run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.6.0/cargo-dist-installer.sh | sh" + # We specify bash to get pipefail; otherwise sh won't catch that curl returned non-0 + shell: bash + run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.7.1/cargo-dist-installer.sh | sh" # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -150,13 +152,13 @@ jobs: runs-on: "ubuntu-latest" env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - BUILD_MANIFEST_NAME: target/distrib/dist-manifest.json + BUILD_MANIFEST_NAME: target/distrib/global-dist-manifest.json steps: - uses: actions/checkout@v4 with: submodules: recursive - name: Install cargo-dist - run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.6.0/cargo-dist-installer.sh | sh" + run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.7.1/cargo-dist-installer.sh | sh" # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -200,7 +202,7 @@ jobs: with: submodules: recursive - name: Install cargo-dist - run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.6.0/cargo-dist-installer.sh | sh" + run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.7.1/cargo-dist-installer.sh | sh" # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -247,7 +249,7 @@ jobs: # Remove the granular manifests rm -f artifacts/*-dist-manifest.json - name: Upload assets to Github Release - uses: AButler/upload-release-assets@v3.0 + uses: AButler/upload-release-assets@v4.0 with: repo-token: ${{ secrets.GITHUB_TOKEN }} files: "artifacts/*" diff --git a/Cargo.toml b/Cargo.toml index 69f28ec1..f45e995d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -5,15 +5,16 @@ resolver = "2" # Config for 'cargo dist' [workspace.metadata.dist] # The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) -cargo-dist-version = "0.6.0" +cargo-dist-version = "0.7.1" # CI backends to support ci = ["github"] # Target platforms to build apps for (Rust target-triple syntax) -targets = ["x86_64-unknown-linux-gnu", "aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-pc-windows-msvc"] +targets = ["x86_64-unknown-linux-gnu", "aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-unknown-linux-musl", "x86_64-pc-windows-msvc"] # The installers to generate for each app -installers = [] +installers = ["shell", "msi"] # Publish jobs to run in CI pr-run-mode = "plan" +# Skip checking whether the specified configuration files are up to date allow-dirty = ["ci"] # generated by 'cargo dist init' [profile.dist] diff --git a/server/Cargo.toml b/server/Cargo.toml index 2d98f678..667bfd75 100644 --- a/server/Cargo.toml +++ b/server/Cargo.toml @@ -14,6 +14,12 @@ name = "unleash-edge" repository = "https://github.com/Unleash/unleash-edge" version = "16.1.0" +[package.metadata.wix] +upgrade-guid = "11E5D83A-3034-48BB-9A84-9F589EBD648C" +path-guid = "6F606A3B-C7E9-43EC-8B6E-91D7B74F80FC" +license = false +eula = false + [dependencies] actix-cors = "0.7.0" actix-http = { version = "3.5.1", features = ["compress-zstd", "rustls-0_21"] } diff --git a/server/wix/main.wxs b/server/wix/main.wxs new file mode 100644 index 00000000..068f465c --- /dev/null +++ b/server/wix/main.wxs @@ -0,0 +1,228 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 + 1 + + + + + + + + + + + + + + + + + +