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

[skip-ci] TMT: revdep podman build test #1892

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

lsm5
Copy link
Member

@lsm5 lsm5 commented Mar 6, 2024

No description provided.

Copy link

Failed to load packit config file:

Cannot parse package config. ValidationError({'jobs': {0: {'common': ["'specfile_path' is not specified or no specfile was found in the repo"]}}})

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

1 similar comment
Copy link

Failed to load packit config file:

Cannot parse package config. ValidationError({'jobs': {0: {'common': ["'specfile_path' is not specified or no specfile was found in the repo"]}}})

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

@lsm5 lsm5 marked this pull request as draft March 6, 2024 13:56
Copy link

Failed to load packit config file:

Cannot parse package config. ValidationError({'jobs': {0: {'common': ["'specfile_path' is not specified or no specfile was found in the repo"]}}})

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

@lsm5 lsm5 changed the title TMT: revdep podman build test [skip-ci] TMT: revdep podman build test Mar 6, 2024
@lsm5 lsm5 force-pushed the tmt-podman-revdep branch 5 times, most recently from a7c3e39 to 815cd3a Compare March 6, 2024 14:50
@lsm5
Copy link
Member Author

lsm5 commented Mar 6, 2024

@Luap99 @edsantiago @TomSweeneyRedHat PTAL. Still in draft and not ready for merge either way, but if this looks ok for starters, I'd like further comments on the test matrix to enable. Right now it's only fedora-rawhide-x86_64.

plans/podman_build_test.sh Outdated Show resolved Hide resolved
@lsm5
Copy link
Member Author

lsm5 commented Mar 11, 2024

Copy link
Member

@Luap99 Luap99 left a comment

Choose a reason for hiding this comment

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

I am not so sure how much value a build test adds, IMO build breaks are generally known by the submitter/reviewer. I guess it adds some value to prevent accidental breakages but I don't think they are very common.

I am not against doing something like this but I think we should have proper discussion first. And as a PoC could you add a "broken" commit here to see how this would look like when it fails?

plans/podman_build_test.sh Outdated Show resolved Hide resolved
git clone https://github.com/containers/podman

cd podman
dnf -y builddep rpm/podman.spec
Copy link
Member

Choose a reason for hiding this comment

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

shouldn't this stuff be installed in the prepare step?

Copy link
Member Author

Choose a reason for hiding this comment

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

That would be doable if we're only running podman tests. If we also want to do buildah, skopeo and anything else, then probably best done in individual tests.

plans/main.fmf Outdated
summary: Build Podman
execute:
how: tmt
script: bash ./plans/podman_build_test.sh
Copy link
Member

Choose a reason for hiding this comment

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

As it's not directly related to building, running, or documenting podman perhaps this could live under ./contrib/tmtplans or similar?

Copy link
Member Author

Choose a reason for hiding this comment

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

will try with this change.

plans/podman_build_test.sh Outdated Show resolved Hide resolved

if [ -f /etc/fedora-release ]; then
export TMPDIR=/var/tmp
fi
Copy link
Member

Choose a reason for hiding this comment

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

It's unclear to me (a lay person, non-tmt expert) why this is needed. Perhaps a comment would be helpful to other non-experts?

plans/podman_build_test.sh Outdated Show resolved Hide resolved
Comment on lines 20 to 23
git add vendor/
git config --global user.email "[email protected]"
git config --global user.name "Your Name"
git commit -am 'add vendored files'
Copy link
Member

Choose a reason for hiding this comment

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

Consider grouping all the git repository setup steps together. It will make both the logs and the script easier to read and maintain.

@TomSweeneyRedHat
Copy link
Member

It would be nice to get @edsantiago 's eyeballs on this if you have the time to wait.

@lsm5 lsm5 marked this pull request as draft March 12, 2024 13:24
@lsm5 lsm5 force-pushed the tmt-podman-revdep branch from deaa412 to 07b3064 Compare March 15, 2024 15:15
@@ -0,0 +1,24 @@
#!/usr/bin/env bash

set -eox pipefail
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
set -eox pipefail
set -exo pipefail

The order here is important.

Copy link
Member

@edsantiago edsantiago left a comment

Choose a reason for hiding this comment

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

Quick first pass. Please also address Chris's comment.

Comment on lines +7 to +9
if [ -f /etc/fedora-release ]; then
export TMPDIR=/var/tmp
fi
Copy link
Member

Choose a reason for hiding this comment

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

Why the conditional? In all test environments I've seen, /var/tmp is much bigger than /tmp. It seems safest just to universally set TMPDIR=/var/tmp.

Copy link
Member

Choose a reason for hiding this comment

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

Oopsie

export TMPDIR=/var/tmp
fi

git clone https://github.com/containers/podman
Copy link
Member

Choose a reason for hiding this comment

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

This script is named buildah_build_test but there's no buildah anything anywhere?

Now I understand the script names. Suggestion: rename both to "build_XXX" instead of XXX_build? "buildah_build_test," to me, suggests that you are testing buildah's build command.

@lsm5 lsm5 force-pushed the tmt-podman-revdep branch from 07b3064 to 792820c Compare December 17, 2024 12:46
Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

Copy link
Contributor

openshift-ci bot commented Dec 17, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: lsm5
Once this PR has been reviewed and has the lgtm label, please assign giuseppe for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

1 similar comment
Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

@lsm5 lsm5 force-pushed the tmt-podman-revdep branch from 792820c to 5421949 Compare December 17, 2024 12:54
Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

2 similar comments
Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

@lsm5 lsm5 force-pushed the tmt-podman-revdep branch from 5421949 to ea36990 Compare December 17, 2024 12:56
Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

2 similar comments
Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

Copy link

Failed to load packit config file:

Please correct data and retry.

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command validate-config or our pre-commit hooks for validation of the configuration.

@lsm5 lsm5 force-pushed the tmt-podman-revdep branch 2 times, most recently from 1c8ce7d to 0b6bf43 Compare December 17, 2024 14:18
rhel copr targets are often outdated causing failed builds and tests.
Best to only have CentOS Stream targets upstream, so we ensure
everything that enters RHEL at some point has been tested upstream.

Signed-off-by: Lokesh Mandvekar <[email protected]>
@lsm5 lsm5 force-pushed the tmt-podman-revdep branch from 0b6bf43 to d62b3be Compare December 18, 2024 11:14
Co-authored-by: Chris Evich <[email protected]>
Signed-off-by: Lokesh Mandvekar <[email protected]>
@lsm5 lsm5 force-pushed the tmt-podman-revdep branch from d62b3be to ba5008d Compare December 18, 2024 13:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants