Skip to content

Commit 6bcb01e

Browse files
committed
ci: add RPM build
1 parent 5d595bb commit 6bcb01e

1 file changed

Lines changed: 29 additions & 3 deletions

File tree

.github/workflows/release.yaml

Lines changed: 29 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@ env:
1010
RUST_BACKTRACE: 1
1111

1212
jobs:
13-
test:
14-
uses: semantic-release-action/rust/.github/workflows/ci.yml@v5
1513

1614
release:
1715
uses: semantic-release-action/rust/.github/workflows/release-binary.yml@v5
@@ -24,4 +22,32 @@ jobs:
2422
aarch64-apple-darwin
2523
x86_64-unknown-linux-gnu
2624
secrets:
27-
cargo-registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}
25+
cargo-registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}
26+
27+
build-rpm:
28+
name: Build and push RPM
29+
runs-on: "ubuntu-latest"
30+
steps:
31+
32+
- name: Checkout
33+
uses: actions/checkout@v5
34+
35+
- name: Install Rust toolchain
36+
uses: dtolnay/rust-toolchain@master
37+
with:
38+
toolchain: stable
39+
40+
- name: Cache Rust dependencies
41+
uses: Swatinem/rust-cache@v2
42+
43+
- name: Build RPM
44+
run: |
45+
cargo build --release
46+
strip -s target/release/bec_log_ingestor
47+
cargo install cargo-generate-rpm
48+
cargo generate-rpm
49+
50+
- uses: actions/upload-artifact@v4
51+
with:
52+
name: RPM artifact
53+
path: target/generate-rpm/*.rpm

0 commit comments

Comments
 (0)