Skip to content

Commit fdc5c25

Browse files
committed
Set-up packaging for Fedora 30
1 parent 045eb6d commit fdc5c25

File tree

1 file changed

+49
-1
lines changed

1 file changed

+49
-1
lines changed

.github/workflows/ci.yml

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,11 +159,54 @@ jobs:
159159
name: fedora-31-latest
160160
path: pkg/fedora/out/x86_64
161161

162+
build-f30:
163+
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/')
164+
165+
name: Build Fedora 30 package
166+
runs-on: ubuntu-latest
167+
needs: [lint, test]
168+
container: fedora:30
169+
170+
steps:
171+
- name: Checkout code
172+
uses: actions/checkout@v2
173+
174+
- name: Install build dependencies
175+
run: |
176+
dnf distro-sync -y
177+
dnf install -y rpmdevtools rpm-sign 'dnf-command(builddep)'
178+
dnf builddep -y pkg/fedora/surface-control.spec
179+
180+
- name: Build package
181+
run: |
182+
cd pkg/fedora
183+
# Build the .rpm packages
184+
./makerpm
185+
186+
- name: Sign packages
187+
env:
188+
GPG_KEY_ID: 56C464BAAC421453
189+
GPG_KEY: ${{ secrets.SURFACE_GPG_KEY }}
190+
run: |
191+
cd pkg/fedora/out/x86_64
192+
193+
# import GPG key
194+
echo "$GPG_KEY" | base64 -d | gpg --import --no-tty --batch --yes
195+
196+
# sign package
197+
rpm --resign *.rpm --define "_gpg_name $GPG_KEY_ID"
198+
199+
- name: Upload artifacts
200+
uses: actions/upload-artifact@v1
201+
with:
202+
name: fedora-30-latest
203+
path: pkg/fedora/out/x86_64
204+
162205
release:
163206
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/')
164207

165208
name: Publish release
166-
needs: [build-bin, build-deb, build-f31]
209+
needs: [build-bin, build-deb, build-f31, build-f30]
167210
runs-on: ubuntu-latest
168211

169212
steps:
@@ -182,6 +225,11 @@ jobs:
182225
with:
183226
name: fedora-31-latest
184227

228+
- name: Download Fedora 30 artifacts
229+
uses: actions/download-artifact@v1
230+
with:
231+
name: fedora-30-latest
232+
185233
- name: Upload assets
186234
uses: svenstaro/upload-release-action@v1-release
187235
with:

0 commit comments

Comments
 (0)