Feature #195

Please add initscripts for linux systems not using systemd

Added by Pavel Šimerda 12 months ago. Updated 11 months ago.

Status:FeedbackStart date:14.06.2012
Priority:NormalDue date:
Assignee:Tobias Brunner% Done:

0%

Category:-
Target version:-
Resolution:

Description

In Fedora 16/17, we are using systemd, but in EPEL (Enterprise Linux), there is still
upstart with sysvinit-style initscripts. This is the exact patch we use. It will probably
need to be adjusted with respect to #194.

strongswan-init.patch Magnifier (2.49 KB) Pavel Šimerda, 14.06.2012 15:43

strongswan-init.patch Magnifier (2.43 KB) Pavel Šimerda, 19.06.2012 14:57

strongswan-init.patch Magnifier (5.38 KB) Pavel Šimerda, 09.07.2012 01:10

strongswan-init.patch Magnifier (5.83 KB) Pavel Šimerda, 09.07.2012 02:24


Related issues

Related to Bug #194: Please allow simple renaming of files colliding with Open... Closed 14.06.2012

History

#1 Updated by Pavel Šimerda 11 months ago

New version of the patch. Still requires changes to integrate well with
configurable name as in #194.

#2 Updated by Pavel Šimerda 11 months ago

Worth adding to 5.0.0 roadmap?

#3 Updated by Tobias Brunner 11 months ago

  • Status changed from New to Feedback
  • Assignee set to Tobias Brunner

I'm not sure about that. The problem is that most SysV init scripts will vary from distribution to distribution. For instance the functions sourced here from /etc/rc.d/init.d/functions are not available on Debian/Ubuntu based systems (there is no /etc/rc.d there, and /etc/init.d/functions does not exist either).

What could work is perhaps an init script based on the LSB Core Specs, which uses standardized functions provided in /lib/lsb/init-functions. Not sure what Fedora's point of view is on this. At least their packaging doc does not explicitly say if LSB based scripts can be used directly.

Anyway, you as package maintainer choose the variable parts (paths etc. including #194) so writing an appropriate init script fitting the respective distribution should be easy to do (and only needs to be done once, unless the distribution changes their requirements).

There is not much gain in an upstream init script if it has to be modified to make it fit the requirements of specific distributions.

#4 Updated by Pavel Šimerda 11 months ago

Hi again,

I'm attaching a reworked patch that uses autoconf to preprocess the initscript. This patch also simplifies
the Makefile.am of init/systemd. If you don't like something in the patch, feel free to remove it or change it.

I didn't have opportunity for any real testing, yet.

#5 Updated by Pavel Šimerda 11 months ago

First tests revealed broken variable substitution. Fix attached.

Also available in: Atom PDF