mirror of
https://github.com/ekaaty/ca-certificates-brazil.git
synced 2025-12-06 01:22:38 -03:00
Signed-off-by: Leonardo Amaral <contato@leonardoamaral.com.br> Co-authored-by: Leonardo Amaral <contato@leonardoamaral.com.br>
71 lines
1.5 KiB
YAML
71 lines
1.5 KiB
YAML
on:
|
|
workflow_call:
|
|
inputs:
|
|
containers:
|
|
default: "['fedora:latest']"
|
|
required: false
|
|
type: string
|
|
tag:
|
|
required: true
|
|
type: string
|
|
to_release:
|
|
default: "0"
|
|
required: false
|
|
type: string
|
|
version:
|
|
required: true
|
|
type: string
|
|
|
|
defaults:
|
|
run:
|
|
shell: bash
|
|
|
|
jobs:
|
|
build:
|
|
strategy:
|
|
max-parallel: 2
|
|
matrix:
|
|
image: ${{ fromJson(inputs.containers) }}
|
|
runs-on: ubuntu-latest
|
|
container: ${{ matrix.image }}
|
|
|
|
steps:
|
|
- name: Prepare - local checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Prepare - install build dependencies
|
|
run: |
|
|
dnf -y install \
|
|
cmake \
|
|
gcc \
|
|
gcc-c++ \
|
|
git \
|
|
openssl \
|
|
rpm-build \
|
|
rpmdevtools \
|
|
tar
|
|
|
|
- name: Prepare - setup RPM build tree
|
|
run: |
|
|
rpmdev-setuptree
|
|
|
|
- name: Prepare - configure the source
|
|
run: |
|
|
cmake -B $(pwd)/build -S $(pwd)
|
|
|
|
- name: Build - create source tarball and SRPM package
|
|
run: |
|
|
cmake --build $(pwd)/build --target srpm
|
|
|
|
- name: Build - create RPM package
|
|
run: |
|
|
cmake --build $(pwd)/build --target rpms
|
|
|
|
- name: Publish - create GitHub release
|
|
uses: softprops/action-gh-release@v2
|
|
if: inputs.to_release == 1
|
|
with:
|
|
tag_name: ${{ inputs.tag }}
|
|
files: |
|
|
dist/*.rpm
|