mirror of
https://github.com/ekaaty/ca-certificates-brazil.git
synced 2025-12-06 01:22:38 -03:00
Added workflow to build RPM
This commit is contained in:
51
.github/workflows/build-rpm.yml
vendored
Normal file
51
.github/workflows/build-rpm.yml
vendored
Normal file
@@ -0,0 +1,51 @@
|
|||||||
|
name: Build RPM Package
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ main ]
|
||||||
|
pull_request:
|
||||||
|
branches: [ main ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-rpm:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container: fedora-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout source code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: install RPM build tools
|
||||||
|
run: |
|
||||||
|
dnf -y install rpm-build rpmdevtools tar
|
||||||
|
|
||||||
|
- name: Setup RPM build tree
|
||||||
|
run: |
|
||||||
|
rpmdev-setuptree
|
||||||
|
|
||||||
|
- name: Create source tarball
|
||||||
|
run: |
|
||||||
|
cmake -B build -S .
|
||||||
|
cmake --build build --target sdist
|
||||||
|
|
||||||
|
- name: Copy SOURCES and SPEC file
|
||||||
|
run: |
|
||||||
|
mkdir -p ~/rpmbuild/SOURCES
|
||||||
|
cp dist/*.src.tar.gz ~/rpmbuild/SOURCES/
|
||||||
|
cp packaging/pkg.spec.in ~/rpmbuild/SPECS/ca-certificates-brazil.spec
|
||||||
|
|
||||||
|
- name: Build RPM
|
||||||
|
run: |
|
||||||
|
rpmbuild -ba ~/rpmbuild/SPECS/ca-certificates-brazil.spec
|
||||||
|
|
||||||
|
- name: Upload built RPMs
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: built-rpms
|
||||||
|
path: ~/rpmbuild/RPMS/
|
||||||
|
|
||||||
|
- name: Upload built RPMs
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: built-rpms
|
||||||
|
path: ~/rpmbuild/*RPMS/
|
||||||
Reference in New Issue
Block a user