2424 libsasl2-dev \
2525 libssl-dev \
2626 libzstd-dev \
27+ libcurl4-openssl-dev \
2728 cmake \
2829 pkg-config \
2930 clang \
@@ -32,24 +33,29 @@ jobs:
3233 - name : Install Rust
3334 uses : dtolnay/rust-toolchain@stable
3435
36+ - name : Cache cargo
37+ uses : Swatinem/rust-cache@v2
38+
3539 - name : Verify version matches tag
3640 run : |
3741 TAG=${GITHUB_REF#refs/tags/v}
3842 CARGO_VERSION=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[0].version')
3943 if [ "$TAG" != "$CARGO_VERSION" ]; then
40- echo "Tag version ($TAG) does not match Cargo.toml version ($CARGO_VERSION)"
44+ echo "ERROR: Tag version ($TAG) does not match Cargo.toml version ($CARGO_VERSION)"
4145 exit 1
4246 fi
47+ echo "Version check passed: $CARGO_VERSION"
4348
4449 - name : Publish to crates.io
45- run : cargo publish --token ${CARGO_REGISTRY_TOKEN}
50+ run : cargo publish --locked -- token ${CARGO_REGISTRY_TOKEN}
4651 env :
4752 CARGO_REGISTRY_TOKEN : ${{ secrets.CARGO_REGISTRY_TOKEN }}
4853
4954 build-release-binaries :
50- name : Build Release Binaries
55+ name : Build Release Binaries (${{ matrix.asset_name }})
5156 runs-on : ${{ matrix.os }}
5257 strategy :
58+ fail-fast : false
5359 matrix :
5460 include :
5561 - os : ubuntu-latest
6066 target : x86_64-unknown-linux-musl
6167 artifact_name : streamforge
6268 asset_name : streamforge-linux-x86_64-musl
63- - os : windows-latest
64- target : x86_64-pc-windows-msvc
65- artifact_name : streamforge.exe
66- asset_name : streamforge-windows-x86_64.exe
6769 - os : macos-latest
6870 target : x86_64-apple-darwin
6971 artifact_name : streamforge
8486 libsasl2-dev \
8587 libssl-dev \
8688 libzstd-dev \
89+ libcurl4-openssl-dev \
8790 cmake \
8891 pkg-config \
8992 clang \
@@ -98,11 +101,13 @@ jobs:
98101 with :
99102 targets : ${{ matrix.target }}
100103
104+ - name : Cache cargo
105+ uses : Swatinem/rust-cache@v2
106+
101107 - name : Build release binary
102108 run : cargo build --release --locked --target ${{ matrix.target }}
103109
104- - name : Strip binary (Unix)
105- if : matrix.os != 'windows-latest'
110+ - name : Strip binary
106111 run : strip target/${{ matrix.target }}/release/${{ matrix.artifact_name }}
107112
108113 - name : Upload binary to release
@@ -117,7 +122,7 @@ jobs:
117122 build-docker-images :
118123 name : Build and Push Docker Images
119124 runs-on : ubuntu-latest
120- continue-on-error : true # Don't fail release if Docker builds fail
125+ continue-on-error : true
121126 permissions :
122127 contents : read
123128 packages : write
@@ -138,7 +143,7 @@ jobs:
138143 id : version
139144 run : echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
140145
141- - name : Build and push Docker image (dynamic)
146+ - name : Build and push Docker image
142147 uses : docker/build-push-action@v5
143148 with :
144149 context : .
@@ -150,18 +155,6 @@ jobs:
150155 cache-from : type=gha
151156 cache-to : type=gha,mode=max
152157
153- - name : Build and push Docker image (static)
154- uses : docker/build-push-action@v5
155- with :
156- context : .
157- file : ./Dockerfile.static
158- push : true
159- tags : |
160- ghcr.io/${{ github.repository }}:${{ steps.version.outputs.VERSION }}-static
161- ghcr.io/${{ github.repository }}:static
162- cache-from : type=gha
163- cache-to : type=gha,mode=max
164-
165158 build-operator-image :
166159 name : Build and Push Operator Image
167160 runs-on : ubuntu-latest
0 commit comments