-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[CI:BUILD] Packit: add jobs for downstream Fedora package builds #18465
[CI:BUILD] Packit: add jobs for downstream Fedora package builds #18465
Conversation
Failed to load packit config file:
For more info, please check out the documentation or contact the Packit team. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: lsm5 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Failed to load packit config file:
For more info, please check out the documentation or contact the Packit team. |
af2877e
to
38c4793
Compare
c0a8c46
to
afacec4
Compare
@mheon any idea if sqlite3 doesn't play well with centos 8 stream?
works on centos 9 stream and fedora. |
@mheon ignore me, the actual error was |
a2f6fd2
to
af49ef5
Compare
20a8ac8
to
eacef91
Compare
eacef91
to
29c9093
Compare
@lsm5 help please, I'm feeling very dumb. I'm trying to figure out where the new specfile comes from, so I can look at the minimalest set of diffs. I've compared against fedpkg @ main and f38 and f37, and those diffs are huge. Where can I find the smallest set of diffs? Also, when you say "gets synced with fedora dist-git", do you mean that Packit pushes to fedpkg, or that Packit pulls from fedpkg, or something else? I'm guessing Packit pushes something to fedpkg, but am not sure what that looks like ( I realize these are stupid questions, and apologize. |
New specfile But it's not exactly the same. I added a lot of conditionals at the top to make all distro envs happy (centos 8/9). If you ignore the conditionals at the top, there shouldn't be too much difference with the rest. Let me know if any particular diff lines are of concern to you.
Packit pushes to fedpkg. So, downstream is dependent on upstream and all the changes first go upstream. The fedora PR waits on a human for merge, so the ultimate fedora packaging responsibility still depends on humans. Once the PR is merged, packit will handle koji builds and bodhi updates. See builds and updates by the The additional tasks in Main benefit is this now means a single rpm spec file which will be used for:
Not at all, good to have them answered so everyone's willingly on board :D If you need any additional comments in the commit message or spec file, I can add those. Let me know. |
@edsantiago if it makes things easier, I can first push the |
Thanks, but I'm good. Your explanation helped. Am in the middle of reviewing now. |
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.
First pass done. Some concerns, some suggestions, but if this is working right now I'm fine with merging and then adding a followup PR. I'm reluctant to re-review this whole thing again :-)
# Keep Version in upstream specfile at 0. It will be automatically set | ||
# to the correct value by Packit for copr and koji builds. | ||
# IGNORE this comment if you're looking at it in dist-git. | ||
Version: 0 |
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 might like to see a test like
%if %{version} == 0
bail out with a very loud message like "please read the specfile"
(to avoid someone just playing with it).
Again, OK to do 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.
hmm, yes. I think I can stick that in the build section. Thanks for the tip. Let me give it a try.
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'll leave this for the future. It's pretty much impossible for rpmbuild to proceed with the current spec file when Version is 0, so this version check isn't an urgent requirement.
rpm/update-spec-provides.sh
Outdated
# This script will update the Version field in the spec which is set to 0 by | ||
# default. Useful for local manual rpm builds where the Version needs to be set | ||
# correctly. |
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.
Comment is copypasted from the next script, and is misleading. And actually, since this script isn't even used, I might suggest removing it and adding it back when you fix the TODO. I won't block over that though.
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.
err, yes I need to change that comment. I'm actually also checking with the packit people on the side.
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.
updated comment.
# default. Useful for local manual rpm builds where the Version needs to be set | ||
# correctly. | ||
|
||
SPEC_FILE=$(pwd)/podman.spec |
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.
Is this really $(pwd)
? I looked in .packit.yml
and don't see where it cd's to the rpm
directory?
I would rather see something like $(dirname $0)/podman.spec
, it seems safer. But it's very likely that I'm missing a key piece of Packit magic.
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.
update-spec-version.sh
is only if someone needs a manual build or use make package
locally. Doesn't get used by packit. I can update the comment to make that clear.
If you don't wanna review the whole thing again, I can repush only with the |
Up to you. I'm comfortable using |
Get rid of `podman.spec.rpkg` in favour of `rpm/podman.spec` which gets synced with fedora dist-git on every upstream release. The version in the new spec file is set to `0` by default and gets updated by packit automatically on every packit task. For local manual rpm builds using the spec, the helper script in the `rpm/` subdir will update the Version field with the latest version found in the upstream repo. Packit will automatically create a PR on fedora dist-git on every new upstream release. A sample PR will look like: https://src.fedoraproject.org/rpms/container-selinux/pull-request/10# A dry run for this can be triggered using: `$ packit propose-downstream --local-content` To run this command locally, you would need to have your packit user-configuration-file set. Ref: https://packit.dev/docs/configuration/#user-configuration-file along with a fedora api key created at: https://src.fedoraproject.org/settings#nav-api-tab with sufficient ACLs. Also includes a revised `package` Makefile target which will build rpms using `rpm/podman.spec`. Fixes: containers#18421. [NO NEW TESTS NEEDED] Signed-off-by: Lokesh Mandvekar <[email protected]>
f0522b5
to
6003dca
Compare
updated PR with libdm_tag re-added and better comments in spec and the update-spec-provides script. Also check https://src.fedoraproject.org/rpms/podman/pull-request/66#request_diff for a sample of the dist-git diff that would be created when we do a new release. Btw, I've removed the |
@edsantiago PTAL. If all the major comments are addressed, let's get this in. Thanks! |
Btw, I've submitted the spec file change to dist-git rawhide branch already, in case you wanna run another diff between spec files. |
/lgtm |
/cherrypick v4.5 |
@lsm5: #18465 failed to apply on top of branch "v4.5":
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Podman upstream now syncs the rpm spec file with Fedora dist-git. This podman.spec also builds gvisor-tap-vsock as a subpackage which conflicts with the standalone gvisor-tap-vsock package on podman-next. Ref: containers/podman#18465 This commit will disable build tasks on `rhcontainerbot/podman-next` to avoid installation conflicts. The copr build tasks on every PR will still continue to check for any potential build issues. Signed-off-by: Lokesh Mandvekar <[email protected]>
Podman upstream now syncs the rpm spec file with Fedora dist-git. This podman.spec also builds gvisor-tap-vsock as a subpackage which conflicts with the standalone gvisor-tap-vsock package on podman-next. Ref: containers/podman#18465 This commit will disable build tasks on `rhcontainerbot/podman-next` to avoid installation conflicts. The copr build tasks on every PR will still continue to check for any potential build issues. Signed-off-by: Lokesh Mandvekar <[email protected]>
The packit workflow for Podman and other repos has recently changed to include the official rpm spec file upstream and have Fedora dist-git sync from upstream on every release. Ref: containers/podman#18465 This has made it necessary to verify ELN package build success in our copr builds. And enabling ELN on copr is causing conmon-rs failures Ref: https://copr.fedorainfracloud.org/coprs/rhcontainerbot/podman-next/build/6121423/ Since ELN is not an immediate concern, this commit will only do copr builds for centos stream and fedora rawhide, 38 and 37. Signed-off-by: Lokesh Mandvekar <[email protected]>
Get rid of
podman.spec.rpkg
in favour ofrpm/podman.spec
which gets synced with fedora dist-git on every upstream release. The version in the new spec file is set to0
by default and gets updated by packit automatically on every packit task.For local manual rpm builds using the spec, the helper script in the
rpm/
subdir will update the Version field with the latest version found in the upstream repo.Packit will automatically create a PR on fedora dist-git on every new upstream release. A sample PR will look like:
https://src.fedoraproject.org/rpms/container-selinux/pull-request/10#
A dry run for this can be triggered using:
$ packit propose-downstream --local-content
To run this command locally, you would need to have your packit user-configuration-file set.
Ref: https://packit.dev/docs/configuration/#user-configuration-file
along with a fedora api key created at:
https://src.fedoraproject.org/settings#nav-api-tab with sufficient ACLs.
Also includes a revised
package
Makefile target which will build rpmsusing
rpm/podman.spec
. Fixes: #18421.[NO NEW TESTS NEEDED]
Does this PR introduce a user-facing change?