-
Notifications
You must be signed in to change notification settings - Fork 16
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
Add initial support for building sambacc rpms via COPR #78
Add initial support for building sambacc rpms via COPR #78
Conversation
@Mergifyio rebase |
🎉 All dependencies have been resolved ! |
❌ Unable to rebase: user
|
@Mergifyio rebase |
✅ Branch has been successfully rebased |
268f6f5
to
ea38746
Compare
I've added the do-not-merge label to block automerging until samba-container is able to correctly deal with >1 rpm in the "distdir". Please do review the code! |
@phlogistonjohn wrote:
I do not quite get the connection to samba-container .... 😬 |
Right now, sambacc gets installed in samba-container images by buidling rpms in a build container and then they get installed by a script that checks that there's only one RPM in the results dir. This PR adds a subpackage to sambacc RPM and so every build will produce at least 2 rpms. We need to make sure that this change wont just break the install script. I was just looking at the script and I think it might be OK beceause the secondary rpms that get created have plus signs (+) in the name where the script only assumes a dash should be. But I haven't tested it yet. |
Locally building samba-container server using this branch for sambacc worked OK for me. Removing label. |
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 don't know enough python to provide a deeper review but some typos (I guess) caught my attention . Apart from those, the patches look good to me.Apart from those, the changes look good to me
If jsonschema module doesn't understand our schemas then we assume that the version is too old and we should treat it the same as not having jsonschema installed. We recently found that having older jsonschema versions present in the container actually breaks sambacc. Because we prefer to install from rpm packages rather than pip in samba-container we ended up with older, and an untested version, of the library. This change tries to make the sambacc code more robust in that case. Signed-off-by: John Mulligan <[email protected]>
Signed-off-by: John Mulligan <[email protected]>
ea38746
to
6191a54
Compare
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.
my previous request has been addressed. remaining request is to fix the typo that @anoopcs9 had already mentioned ...
When a generated srpm was submitted to COPR it failed due to the check phase running the tests and failing due to missing samba components. Explicitly add some of those components to the spec. Signed-off-by: John Mulligan <[email protected]>
Signed-off-by: John Mulligan <[email protected]>
Clean up how the arguments passed to rpmbuild are written. Signed-off-by: John Mulligan <[email protected]>
When using the container to build "binary" rpms passing the pversion and rversion vars mostly worked, but the srpm it generated was not usable. This change generates a new spec file based on the old, but with pversion and rversion predefined, based on the same setuptools_scm values, such that the srpm is usable in other environments. Signed-off-by: John Mulligan <[email protected]>
Signed-off-by: John Mulligan <[email protected]>
Signed-off-by: John Mulligan <[email protected]>
6191a54
to
ddb33b2
Compare
This is considered the flexible way to build in COPR and it meets our needs to match the setuptools_scm versionoing scheme we've already been using for a while. Hackily reuse the container build.sh script for generating the srpm. Signed-off-by: John Mulligan <[email protected]>
76b4802
to
1dfbc53
Compare
Much appreciated. |
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.
lgtm
Depends on: #77
Another grab bag of changes that work up to getting basic support for COPR in place.
Prepare sambacc and the rpm spec file for optional dependencies.
Fix the rpm spec generation to work correctly outside our container env.
Make the build.sh script flexible enough to be reused in the COPR environment. Add a .copr/Makefile for the COPR system to build SRPMs directly from the git checkout.