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

Packit: initial enablement #2

Merged
merged 1 commit into from
Apr 3, 2023
Merged

Packit: initial enablement #2

merged 1 commit into from
Apr 3, 2023

Conversation

lsm5
Copy link
Member

@lsm5 lsm5 commented Mar 21, 2023

This commit adds Packit configuration files which will trigger builds on
copr:rhcontainerbot/packit-builds on every PR and on
copr:rhcontainerbot/podman-next on every commit to main branch.

Signed-off-by: Lokesh Mandvekar [email protected]

@lsm5
Copy link
Member Author

lsm5 commented Mar 21, 2023

/packit copr-build

@lsm5
Copy link
Member Author

lsm5 commented Mar 21, 2023

@rhatdan looks like make man can't be done without superuser. Are you cool with adding a generated qm_selinux.8 into the repo as in container-selinux ?

$ make man
make -f /usr/share/selinux/devel/Makefile qm.pp
make[1]: Entering directory '/home/lsm5/repositories/qm-selinux'
qm.if:14: Warning: duplicate definition of qm_domain_template(). Original definition on /usr/share/selinux/devel/include/services/qm.if:14.
Compiling targeted qm module
Creating targeted qm.pp policy package
rm tmp/qm.mod tmp/qm.mod.fc
make[1]: Leaving directory '/home/lsm5/repositories/qm-selinux'
Compressing qm.pp -> qm.pp.bz2
bzip2 -f -9 qm.pp
semodule -i qm.pp.bz2
libsemanage.semanage_create_store: Could not read from module store, active modules subdirectory at /var/lib/selinux/targeted/active/modules. (Permission denied).

@lsm5 lsm5 force-pushed the packit branch 3 times, most recently from 97f12ad to 4acafd4 Compare March 21, 2023 12:22
qm_selinux.8 Show resolved Hide resolved
@lsm5 lsm5 force-pushed the packit branch 2 times, most recently from 0acb018 to 267bb25 Compare March 22, 2023 15:09
qm-selinux.spec.rpkg Outdated Show resolved Hide resolved
%dir %{_sharedstatedir}/qm/rootfs%{_datadir}/containers
%{_sharedstatedir}/qm/rootfs%{_datadir}/containers/container_contexts
%dir %{_libexecdir}/%{name}
%{_libexecdir}/%{name}/install.sh
Copy link
Member Author

Choose a reason for hiding this comment

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

@rhatdan added the install.sh script to /usr/libexec/qm-selinux . Please verify the change and remind me what else I need to add.

Copy link
Member

Choose a reason for hiding this comment

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

I think we should name this /usr/libexec/qm-install

I am thinking of renaming this repo to just qm

Copy link
Member Author

Choose a reason for hiding this comment

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

I think we should name this /usr/libexec/qm-install

I think the script should be 1 level further down. So, inside /usr/libexec/qm/ or if it's only to be used in conjunction with podman, maybe in /usr/libexec/podman/.

I am thinking of renaming this repo to just qm

Dunno, I guess having the -selinux in the name provides a better idea, but not a stong opinion. We could check with the team if you prefer.

Copy link
Member

Choose a reason for hiding this comment

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

Yes, /usr/libexec/qm/install would be good.
Or /usr/lib/qm/install since this is not to be executed by other users of a tool.

As far as the -selinux drop is concerned, the goal of this repo is setting up a QM isolated environment. The SELinux component is just a small part of it.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, /usr/libexec/qm/install would be good. Or /usr/lib/qm/install since this is not to be executed by other users of a tool.

As far as the -selinux drop is concerned, the goal of this repo is setting up a QM isolated environment. The SELinux component is just a small part of it.

SGTM

Copy link
Member Author

Choose a reason for hiding this comment

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

file path changed. PTAL

@lsm5 lsm5 marked this pull request as ready for review March 22, 2023 15:31
@lsm5 lsm5 changed the title [DO NOT MERGE] Packit: initial enablement Packit: initial enablement Mar 22, 2023
This commit adds Packit configuration files which will trigger builds on
copr:`rhcontainerbot/packit-builds` on every PR and on
copr:`rhcontainerbot/podman-next` on every commit to main branch.

Signed-off-by: Lokesh Mandvekar <[email protected]>
@lsm5
Copy link
Member Author

lsm5 commented Mar 24, 2023

@rhatdan also added qm.container to /usr/share/containers/systemd/ . PTAL at the new change.

Could you please also remind me of the exact rpm testing steps?

Right now I have:

$ /usr/lib/qm/install
+ sudo systemctl stop qm
+ sudo podman volume rm qmEtc qmVar --force
+ make
make: *** No targets specified and no makefile found.  Stop.

@rhatdan
Copy link
Member

rhatdan commented Mar 25, 2023

Ok I the setup script needs to be modified to expect that the qm-selinux package was already built.

@lsm5
Copy link
Member Author

lsm5 commented Apr 3, 2023

Ok I the setup script needs to be modified to expect that the qm-selinux package was already built.

@rhatdan ping, just checking if you've updated the script.

@rhatdan
Copy link
Member

rhatdan commented Apr 3, 2023

I have not completed it yet, hopefully I will get back to this tomorrow.

@rhatdan
Copy link
Member

rhatdan commented Apr 3, 2023

Ok I am going to merge, and then we can continue working and improving this.

@rhatdan rhatdan merged commit 46fe357 into containers:main Apr 3, 2023
@lsm5 lsm5 deleted the packit branch April 14, 2023 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants