Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RHEL 10 branch CI -- sync with the main branch #1284

Merged
merged 6 commits into from
Sep 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/anaconda_tests.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
name: Run validation tests from Anaconda
on: pull_request
on:
pull_request:
branches:
- main

permissions:
contents: read
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/check-rhel.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Static Analysis (RHEL)

on:
pull_request:
branches:
- rhel10-branch

jobs:
build:
name: static-analysis-rhel
runs-on: ubuntu-24.04
env:
CI_IMAGE: quay.io/centos/centos:stream10-development
CI_CONTAINER: blivet-tests
steps:
- name: Checkout blivet repository
uses: actions/checkout@v4

- name: Install podman
run: |
sudo apt -qq update
sudo apt -y -qq install podman

- name: Start the container
run: |
podman run -d -t --name ${{ env.CI_CONTAINER }} --privileged --volume "$(pwd):/app" --workdir "/app" ${{ env.CI_IMAGE }}

- name: Install ansible in the container
run: |
podman exec -it ${{ env.CI_CONTAINER }} bash -c "dnf -y install ansible-core make which"

- name: Install test dependencies in the container
run: |
podman exec -it ${{ env.CI_CONTAINER }} bash -c "ansible-playbook -i 'localhost,' -c local misc/install-test-dependencies.yml"

- name: Run static analysis tests in the container
run: |
podman exec -it ${{ env.CI_CONTAINER }} bash -c "make check"
27 changes: 24 additions & 3 deletions .packit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,24 +15,43 @@ actions:
- bash -c "sed -i python-blivet.spec -e \"s/Release:.*/Release:\ ${PACKIT_RPMSPEC_RELEASE}%{?dist}/\""

jobs:
# Fedora builds for the 'main' branch
- job: copr_build
metadata:
targets:
targets:
- fedora-all
trigger: pull_request
branch: main

# CentOS 10 Stream builds for the 'rhel10-branch'
- job: copr_build
targets:
- centos-stream-10-x86_64
trigger: pull_request
branch: rhel10-branch

# Daily builds for Fedora from the 'main' branch
- job: copr_build
trigger: commit
owner: "@storage"
project: blivet-daily
branch: main
preserve_project: true

# Fedora tests for the 'main' branch
- job: tests
trigger: pull_request
targets:
- fedora-latest-stable
branch: main

# CentOS 10 Stream tests for the 'rhel10-branch'
- job: tests
trigger: pull_request
targets:
- centos-stream-10-x86_64
branch: rhel10-branch

# Downstream builds
- job: propose_downstream
trigger: release
dist_git_branches:
Expand All @@ -48,10 +67,12 @@ jobs:
dist_git_branches:
- fedora-branched

# run tests for udisks consumers, see plans/ with `revdeps == yes`
# Reverse dependency tests
## run tests for blivet consumers, see plans/ with `revdeps == yes`
- job: tests
identifier: revdeps
trigger: pull_request
branch: main
notifications:
failure_comment:
message: "Blivet-GUI tests failed for commit {commit_sha}. @vojtechtrefny please check."
Expand Down
16 changes: 16 additions & 0 deletions plans/tests-rhel.fmf
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
summary: Run tests

adjust+:
- when: revdeps == yes
enabled: false
- when: distro == fedora
enabled: false

prepare:
- name: ansible
how: ansible
playbook: misc/install-test-dependencies.yml

execute:
how: tmt
script: sudo make test
6 changes: 4 additions & 2 deletions plans/tests.fmf
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
summary: Run tests

adjust+:
when: revdeps == yes
enabled: false
- when: revdeps == yes
enabled: false
- when: distro == centos
enabled: false

prepare:
- name: copr
Expand Down