RIPE-NCC / rpki-validator

Other
64 stars 20 forks source link

RPM/Debian packages #8

Closed dkowis closed 7 years ago

dkowis commented 10 years ago

Came here from the tweet. Making this so that I can document how the RPM/Deb's should look

For each project:

For the validator-app

No guarantees that I can do all this, but someone building the packages is going to need this info :)

lolepezy commented 10 years ago

Hi David, thanks for your response. Some thought/answers below.

How do you want the installation to happen? We though about something like dpkg -i rpki-validator-2.X.X.deb and RPM analog of that. That would be the first stage. The second thing we have in mind is to host a repo (well, one repo for DEB, one for RPM).

Why is one project building a .tar.gz and the other building a .zip? For historical reasons, I'd say. The CLI application is supposed to disappear, so we could basically focus on the daemon (which is packed into tar.gz). So CLI subproject can be safely ignored.

The CLI builds a shaded jar, but the other uses a library directory, is this intentional? That's legacy as well, we'll keep only one way, which is lib directory.

Do you want to put the shell scripts into /usr/bin so they show up as > "real" binaries? (we'll need to change how it looks for basedirs) The answer is most probably "no". The only thing those scripts do is being called by some /etc/init.d/rpki-validator-init script and start/stop/request status. There is basically no any other use for them.

There's a dist tarball that's created (although the root directory has zero permissions), do you want an extraction of that? In the current setup we unpack the whole tarball to some directory and just use the unpacked stuff. So, the easiest way that will work is to extract the tarball somewhere and make /etc/init.d/rpki-validator-init be aware of that location. By "somewhere" I mean some available location such as "var/lib/xxx" or "/usr/local/xxx", for example.

What permissions do the directories within there need? (conf data lib log)

conf - 400 data - 600 lib - 500 log - 644

In principle, we can scatter them in a proper way, for instance, conf -> /etc/rpki-validator.conf.d data -> /var/lib/rpki-validator/ lib -> /var/lib/rpki-validator/lib log -> /var/log/rpki-validator.d/ That will, maybe, require some source modifications, but tiny ones.

Do you want a user for the thing, or install/run everything as nobody? Nobody is good enough :).

Do you want an init script? (The shell script is almost an init script, but it needs some help) We have one, and we'll add it to the project.

No guarantees that I can do all this, but someone building the packages is going to need this info :)

Well, at least sorting that all out will already bring us much closer to the end :)

timbru commented 7 years ago

We had no response for a while so we hope this addressed the issue. More importantly our main development effort is now on validator-3, and we want to make sure that packaging is done properly in that version.