-
Notifications
You must be signed in to change notification settings - Fork 3.1k
[skip-ci] TMT: run system tests on Fedora #24369
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
Merged
+273
−2
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,59 @@ | ||
| discover: | ||
| how: fmf | ||
|
|
||
| execute: | ||
| how: tmt | ||
|
|
||
| prepare: | ||
| - how: shell | ||
| script: modprobe null_blk nr_devices=1 | ||
| order: 5 | ||
| - 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 | ||
|
|
||
| adjust+: | ||
| - enabled: false | ||
| when: revdeps == yes | ||
|
|
||
| provision: | ||
| how: artemis | ||
| hardware: | ||
| memory: ">= 16 GB" | ||
| cpu: | ||
| cores: ">= 4" | ||
| threads: ">=8" | ||
| disk: | ||
| - size: ">= 512 GB" | ||
|
|
||
| /local-root: | ||
| summary: Local rootful tests | ||
| discover+: | ||
| filter: 'tag:local & tag:root' | ||
|
|
||
| /local-rootless: | ||
| summary: Local rootless tests | ||
| discover+: | ||
| filter: 'tag:local & tag:rootless' | ||
|
|
||
| /remote-root: | ||
| summary: Remote rootful tests | ||
| discover+: | ||
| filter: 'tag:remote & tag:root' | ||
|
|
||
| /remote-rootless: | ||
| summary: Remote rootless tests | ||
| discover+: | ||
| filter: 'tag:remote & tag:rootless' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| summary: Run tmt container provision test (downstream only) | ||
|
|
||
| enabled: false | ||
| adjust+: | ||
| - enabled: true | ||
| when: initiator != packit and distro != rhel | ||
|
|
||
| discover: | ||
| how: fmf | ||
| filter: 'tag:tmt & tag:downstream' | ||
|
|
||
| execute: | ||
| how: tmt | ||
|
|
||
| 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 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| summary: Run toolbox tests (downstream only) | ||
|
|
||
| enabled: false | ||
| adjust+: | ||
| - enabled: true | ||
| when: initiator != packit and distro == fedora | ||
|
|
||
| provision: | ||
| how: artemis | ||
| hardware: | ||
| memory: ">= 16 GB" | ||
| cpu: | ||
| cores: ">= 4" | ||
| threads: ">=8" | ||
| disk: | ||
| - size: ">= 512 GB" | ||
|
|
||
| prepare: | ||
| - name: packages | ||
| how: install | ||
| package: [toolbox-tests] | ||
|
|
||
| discover: | ||
| how: fmf | ||
| url: https://src.fedoraproject.org/rpms/toolbox | ||
| ref: "rawhide" | ||
|
|
||
| execute: | ||
| how: tmt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| --- !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} | ||
|
|
||
| # recipients: jnovy, lsm5, santiago | ||
| --- !Policy | ||
| product_versions: | ||
| - rhel-* | ||
| decision_context: osci_compose_gate | ||
| rules: | ||
| - !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,48 @@ | ||
| require: | ||
| - podman-tests | ||
| - psmisc | ||
|
|
||
| environment: | ||
| # PODMAN_TESTING envvar is set in system.sh | ||
| PODMAN: /usr/bin/podman | ||
| QUADLET: /usr/libexec/podman/quadlet | ||
| ROOTLESS_USER: "fedora" | ||
| adjust+: | ||
| - when: distro == centos-stream | ||
| environment+: | ||
| ROOTLESS_USER: "ec2-user" | ||
| - when: distro == rhel | ||
| environment+: | ||
| ROOTLESS_USER: "cloud-user" | ||
|
|
||
| /local-root: | ||
| tag: [ local, root ] | ||
| summary: local rootful test | ||
| test: bash ./system.sh | ||
| duration: 30m | ||
|
|
||
| /local-rootless: | ||
| tag: [ local, rootless ] | ||
| summary: rootless test | ||
| test: bash ./system.sh rootless | ||
| duration: 30m | ||
|
|
||
| /remote-root: | ||
| tag: [ remote, root ] | ||
| summary: remote rootful test | ||
| test: bash ./system.sh | ||
| duration: 30m | ||
| environment+: | ||
| PODMAN: /usr/bin/podman-remote | ||
| require+: | ||
| - podman-remote | ||
|
|
||
| /remote-rootless: | ||
| tag: [ remote, rootless ] | ||
| summary: remote rootless test | ||
| test: bash ./system.sh rootless | ||
| duration: 30m | ||
| environment+: | ||
| PODMAN: /usr/bin/podman-remote | ||
| require+: | ||
| - podman-remote |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| #!/usr/bin/env bash | ||
|
|
||
| set -exo pipefail | ||
|
|
||
| uname -r | ||
|
|
||
| loginctl enable-linger "$ROOTLESS_USER" | ||
|
|
||
| rpm -q \ | ||
| aardvark-dns \ | ||
| buildah \ | ||
| conmon \ | ||
| container-selinux \ | ||
| containers-common \ | ||
| criu \ | ||
| crun \ | ||
| netavark \ | ||
| passt \ | ||
| podman \ | ||
| podman-tests \ | ||
| skopeo \ | ||
| slirp4netns \ | ||
| systemd | ||
|
|
||
| export system_service_cmd="/usr/bin/podman system service --timeout=0 &" | ||
| export test_cmd="whoami && cd /usr/share/podman/test/system && PODMAN_TESTING=/usr/bin/podman-testing bats ." | ||
|
|
||
| if [[ -z $1 ]]; then | ||
| if [[ $PODMAN == "/usr/bin/podman-remote" ]]; then | ||
| eval "$system_service_cmd" | ||
| fi | ||
| eval "$test_cmd" | ||
| elif [[ $1 == "rootless" ]]; then | ||
| if [[ $PODMAN == "/usr/bin/podman-remote" ]]; then | ||
| su - "$ROOTLESS_USER" -c "eval $system_service_cmd" | ||
| fi | ||
| su - "$ROOTLESS_USER" -c "eval $test_cmd" | ||
| fi | ||
|
|
||
| # Kill all podman processes for remote tests | ||
| if [[ $PODMAN == "/usr/bin/podman-remote" ]]; then | ||
| killall -q podman | ||
| fi | ||
| exit 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| enabled: false | ||
| adjust: | ||
| enabled: true | ||
| when: initiator != packit && distro != rhel | ||
| summary: Make sure that TMT container provision works | ||
| tag: [downstream] | ||
| require: | ||
| - tmt+provision-container | ||
| test: | ||
| tmt run --verbose --remove | ||
| provision --how container --image fedora | ||
| login --command 'cat /etc/os-release' | ||
| finish |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we have a reason why not to follow packit aliases to follow fedora releases? these will need to be bumped
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did this because f40 and aarch64 tests were failing. aarch64 had some criu issues and F40 I don't quite remember what.
This is only a short term thing, and I would like to follow up with enablements for centos stream and all active fedora as well as aarch64