Overview

Request 584508 superseded

I have added hostinfo Uninstall to preun, because the hostinfo.service is not always running. It is run by the hostinfo.timer so trap SIGTERM fails. I use /run/issue.d so /etc/issue.d can be used as an override. I do not use /usr/lib/issue.d because it will interfere with issue-generator if hostinfo is uninstalled.

Loading...

Dominique Leuenberger's avatar

+gzip -9f man/*8

There is an rpm build root policy in place compressing the man pages into a distro standard format (for now gz, but that could change)


Dominique Leuenberger's avatar

+install -m 644 conf/10-hostinfo.preset %{buildroot}%{_presetdir}

I honestly doubt that this is the correct way to go - I said before that enabling the service is not the package's responsibility

Hiding it away in a file like this won't make me not see it.


Jason Record's avatar

I'm not trying to hide it so you can't see it. It has been there all along. There are MANY requirements to get the package into Factory. I'm fine with that and am trying to get them all flushed out.


Dominique Leuenberger's avatar

Good; then I'm sorry I did not mention this one earlier;

I'm actually a bit surprised that this made it into SLE - the requirements are actually aligned when it comes to this kind of things


Dominique Leuenberger's avatar

One more thing:

+Source: %{name}-%{version}.tar.gz

It's not disallowed, but discouraged. Much better would be to have a full URL where to download the tarball, so that things are verifiable/reprodicible.

If it is a git snapshot, it might be an option to look into source services, namley tar_scm (or obs_scm); If you're interested in this, the package openSUSE:Factory/appstream-glib could serve as an example


Jason Record's avatar

I will work on this, but I'm worried the package will not make it into SLE15. So I want the package submitted first, and then work on external sources if that's okay. I reviewed the package, but it is not completely clear what I need to do to my package and my github sources.


Dominique Leuenberger's avatar

Sure - as said: 'not forbidden, but discouraged' :)


Dominique Leuenberger's avatar

rpmlint reports:

hostinfo.noarch: W: suse-missing-rclink hostinfo

The fix would be:

ln -sf service %{buildroot}%{_sbindir}/rchostinfo

Jason Record's avatar

I am unclear about: 1. I am also uncertain how to start the hostinfo.timer when the rpm is installed. The presets will enable the server and it works after reboot. However, the customer will have to install the rpm and run systemctl start hostinfo.timer to get things going. Can this be done in another way? 2. I have submit request 584519 for the presets now. It enables the hostinfo.timer and hostinfo.service. 3. I also still need a %preun to remove the files from /run/issue.d per description above.


Dominique Leuenberger's avatar
+%post
+%service_add_post hostinfo.service hostinfo.timer
+if [ -x /usr/bin/systemctl ]; then
+   /usr/bin/systemctl start hostinfo.timer
+fi

This is still invalid practice. Starting a service like this is of very limited use (not preserved across boots) and enabling services is responsibility of preset packages, and not of the packages providing the service.


Request History
Jason Record's avatar

jrecord created request

I have added hostinfo Uninstall to preun, because the hostinfo.service is not always running. It is run by the hostinfo.timer so trap SIGTERM fails. I use /run/issue.d so /etc/issue.d can be used as an override. I do not use /usr/lib/issue.d because it will interfere with issue-generator if hostinfo is uninstalled.


Saul Goodman's avatar

licensedigger accepted review

ok


Factory Auto's avatar

factory-auto added opensuse-review-team as a reviewer

Please review sources


Factory Auto's avatar

factory-auto added repo-checker as a reviewer

Please review build success


Factory Auto's avatar

factory-auto accepted review

Check script succeeded


Dominique Leuenberger's avatar

dimstar added msmeissn as a reviewer

Marcus, please validate, from the PoV sec team.

This package installs a systemd preset file into the system context.

According to my info, this is not allowed; a service we want to have enable upon install should be listed either in systemd-presets-common-SUSE or distro-specific branding variants.


Staging Bot's avatar

staging-bot added as a reviewer

Being evaluated by staging project "openSUSE:Factory:Staging:adi:46"


Staging Bot's avatar

staging-bot accepted review

Picked openSUSE:Factory:Staging:adi:46


Repo Checker's avatar

repo-checker accepted review

cycle and install check passed


Jason Record's avatar

jrecord superseded request

superseded by 584542

openSUSE Build Service is sponsored by