-
Notifications
You must be signed in to change notification settings - Fork 0
58 lines (54 loc) · 1.75 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: RPM - Repository
on:
push:
branches: [ master, develop ]
tags: [ '*' ]
pull_request:
branches: [ master, develop ]
workflow_dispatch:
jobs:
get_fedora_releases:
name: Get Fedora Releases
runs-on: ubuntu-latest
steps:
- name: Query Fedora
id: releases
uses: sgallagher/get-fedora-releases-action@v1
outputs:
stable: ${{ steps.releases.outputs.stable }}
development: ${{ steps.releases.outputs.development }}
active: ${{ steps.releases.outputs.active }}
build:
name: Build (Active)
needs: get_fedora_releases
continue-on-error: false
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
os-type: [fedora]
os-version: ${{ fromJson(needs.get_fedora_releases.outputs.stable) }}
container: ${{ matrix.os-type }}:${{ matrix.os-version }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Get package name and version
id: package-version
uses: astrorama/actions/[email protected]
- name: Install dependencies
uses: astrorama/actions/[email protected]
with:
dependency-list: .github/workflows/dependencies.txt
- name: Build
id: build
uses: astrorama/actions/[email protected]
- name: Upload RPM to repository
uses: astrorama/actions/[email protected]
if: ${{ github.repository_owner == 'astrorama' }}
env:
REPOSITORY_USER: ${{ secrets.REPOSITORY_USER }}
REPOSITORY_PASSWORD: ${{ secrets.REPOSITORY_PASSWORD }}
REPOSITORY_KEY: ${{ secrets.REPOSITORY_KEY }}
with:
rpm-dir: ${{ steps.build.outputs.rpm-dir }}
srpm-dir: ${{ steps.build.outputs.srpm-dir }}