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

Introduce nosync to speed up installability #38

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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: 5 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,11 @@ pipeline {
[
arch: "x86_64",
os: [ compose: "${config.compose}" ],
tmt: [
context: [
profile: "${config.profile_name}"
]
],
variables: [
PROFILE_NAME: "${config.profile_name}",
TASK_ID: "${getIdFromArtifactId(artifactId: artifactId)}",
Expand Down
7 changes: 7 additions & 0 deletions installability.fmf
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ description: Runs installability tests in Fedora CI — https://github.com/fedor
provision:
how: virtual

adjust:
- when: profile == fedora
prepare+:
- script: dnf -y install nosync
environment+:
LD_PRELOAD: /usr/lib64/nosync/nosync.so

discover:
how: shell
tests:
Expand Down
6 changes: 6 additions & 0 deletions prepare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ dnf -y copr enable @osci/mini-tps
dnf -y install mini-tps
dnf -y copr disable @osci/mini-tps

# Use nosync to speed up dnf
if grep -q fedora <<< "${PROFILE_NAME}"; then
dnf -y install nosync
export LD_PRELOAD=/usr/lib64/nosync/nosync.so
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suspect that this env var is only set in the prepare test, and not in the subsequent installability test -- tmt likely spawns a new shell process for that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am wondering if it would be better to simply enable nosync in mini-tps directly?

fi

# make sure mini-tps can find Koji
# TODO: can mini-tps RPM package provide this configuration automatically?
mkdir -p /var/tmp/mini-tps/ /usr/local/libexec/mini-tps/
Expand Down
Loading