Skip to content

Install .rpm packages and try conversion on them #46

Install .rpm packages and try conversion on them

Install .rpm packages and try conversion on them #46

---
name: check-packages
on: [push, pull_request]
jobs:
check-sigs:
runs-on: ubuntu-latest
container:
image: fedora:37
steps:
- name: Install RPM packaging dependencies
run: yum -y update && yum -y install git git-lfs
- uses: actions/checkout@v3
with:
lfs: true
- name: Verify signatures on all RPMs
run: |
# git lfs install && git lfs pull
gpg --import fpf-yum-tools-archive-keyring.gpg
./scripts/publish.py --verify --all
build-install-rpm:
name: "Install on Fedora ${{matrix.version}}"
runs-on: ubuntu-latest
strategy:
matrix:
include:
- version: "38"
- version: "39"
- version: "40"
steps:
- name: Checkout dangerzone repo
uses: actions/checkout@v4
with:
repository: freedomofpress/dangerzone
path: main
- name: Checkout yum-tools-prod repo
uses: actions/checkout@v4
with:
path: yum
lfs: 'true'
- name: cp dangerzone .rpm files
run: |
mkdir "./main/dist"
cp ./yum/dangerzone/f${{ matrix.version }}/*.rpm ./main/dist/.
# Rename files to -1.rpm, as this is what's expected
# by the `./dev_scripts/env.py build` command
pushd ./main/dist/
for file in *-*.rpm; do
version="${file%-*}"
rest="${file#*-}"
mv "$file" "${version}-1.${rest##*.}"
done
popd
- name: Build end-user environment
working-directory: main
run: |
./dev_scripts/env.py --distro fedora --version ${{ matrix.version }} build
- name: Run a test command
working-directory: main
run: |
./dev_scripts/env.py --distro fedora --version ${{ matrix.version }} \
run dangerzone-cli dangerzone/tests/test_docs/sample-pdf.pdf
- name: Check that the Dangerzone GUI imports work
working-directory: main
run: |
./dev_scripts/env.py --distro fedora --version ${{ matrix.version }} \
run dangerzone --help