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

TMT: Initial Enablement #538

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
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
1 change: 1 addition & 0 deletions .fmf/version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1
62 changes: 50 additions & 12 deletions .packit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,31 @@
downstream_package_name: conmon
upstream_tag_template: v{version}

# These files get synced from upstream to downstream (Fedora / CentOS Stream) on every
# propose-downstream job. This is done so tests maintained upstream can be run
# downstream in Zuul CI and Bodhi.
# Ref: https://packit.dev/docs/configuration#files_to_sync
files_to_sync:
- src: rpm/gating.yaml
dest: gating.yaml
delete: true
- src: plans/
dest: plans/
delete: true
mkpath: true
- src: .fmf/
dest: .fmf/
delete: true
- .packit.yaml

packages:
conmon-fedora:
pkg_tool: fedpkg
specfile_path: rpm/conmon.spec
conmon-centos:
pkg_tool: centpkg
specfile_path: rpm/conmon.spec
conmon-rhel:
conmon-eln:
specfile_path: rpm/conmon.spec

jobs:
Expand All @@ -23,9 +40,16 @@ jobs:
failure_comment:
message: "Ephemeral COPR build failed. @containers/packit-build please check."
enable_net: true
targets:
targets: &fedora_copr_targets
- fedora-all-aarch64
- fedora-all-x86_64

- job: copr_build
trigger: pull_request
packages: [conmon-eln]
notifications: *copr_build_failure_notification
enable_net: true
targets:
- fedora-eln-aarch64
- fedora-eln-x86_64

Expand All @@ -34,21 +58,12 @@ jobs:
packages: [conmon-centos]
notifications: *copr_build_failure_notification
enable_net: true
targets:
targets: &centos_copr_targets
- centos-stream-10-aarch64
- centos-stream-10-x86_64
- centos-stream-9-aarch64
- centos-stream-9-x86_64

- job: copr_build
trigger: pull_request
packages: [conmon-rhel]
notifications: *copr_build_failure_notification
enable_net: true
targets:
- epel-9-aarch64
- epel-9-x86_64

# Run on commit to main branch
- job: copr_build
trigger: commit
Expand All @@ -60,6 +75,28 @@ jobs:
project: podman-next
enable_net: true

- job: tests
trigger: pull_request
packages: [conmon-fedora]
targets: *fedora_copr_targets
enable_net: true
tf_extra_params:
environments:
- artifacts:
- type: repository-file
id: https://copr.fedorainfracloud.org/coprs/rhcontainerbot/podman-next/repo/fedora-$releasever/rhcontainerbot-podman-next-fedora-$releasever.repo

- job: tests
trigger: pull_request
packages: [conmon-centos]
targets: *centos_copr_targets
enable_net: true
tf_extra_params:
environments:
- artifacts:
- type: repository-file
id: https://copr.fedorainfracloud.org/coprs/rhcontainerbot/podman-next/repo/centos-stream-$releasever/rhcontainerbot-podman-next-centos-stream-$releasever.repo

# Downstream sync for Fedora
- job: propose_downstream
trigger: release
Expand All @@ -75,6 +112,7 @@ jobs:
update_release: false
dist_git_branches:
- c10s
- c9s

- job: koji_build
trigger: commit
Expand Down
34 changes: 34 additions & 0 deletions plans/podman.fmf
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
prepare:
- when: distro == centos-stream or distro == rhel
how: shell
script: |
dnf -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-$(rpm --eval '%{?rhel}').noarch.rpm
dnf -y config-manager --set-enabled epel
order: 10
- when: initiator == packit
how: shell
script: |
COPR_REPO_FILE="/etc/yum.repos.d/*podman-next*.repo"
if compgen -G $COPR_REPO_FILE > /dev/null; then
sed -i -n '/^priority=/!p;$apriority=1' $COPR_REPO_FILE
fi
dnf -y upgrade --allowerasing
order: 20

discover:
how: fmf
url: https://github.com/lsm5/podman
ref: "tmt-fedora-centos"

execute:
how: tmt

/system/local-root:
summary: Run podman system rootful tests
discover+:
test: /test/tmt/system/local-root

/system/local-rootless:
summary: Run podman system rootless tests
discover+:
test: /test/tmt/system/local-rootless
16 changes: 16 additions & 0 deletions rpm/gating.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
--- !Policy
product_versions:
- fedora-*
decision_contexts:
- bodhi_update_push_stable
- bodhi_update_push_testing
subject_type: koji_build
rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}

--- !Policy
product_versions:
- rhel-*
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}
Loading