Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#23935 - Include /etc/conf.d scripts using script name ($0)

Attached to Project: Arch Linux
Opened by Andrej Podzimek (andrej) - Monday, 25 April 2011, 16:29 GMT
Last edited by Tom Gundersen (tomegun) - Tuesday, 08 May 2012, 12:27 GMT
Task Type Feature Request
Category Packages: Core
Status Closed
Assigned To Tom Gundersen (tomegun)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:

Currently, all /etc/rc.d scripts include their /etc/conf.d counterpart using its name explicitly. It would be nicer to derive the conf.d script name from the $0 variable instead.

For instance, if you want to run multiple instances of PostgreSQL, you need to set a different data directory and port for each of them. This could be done by simply creating and editing a copy of /etc/conf.d/postgresql file and creating a symlink:

cp /etc/conf.d/postgresql /etc/conf.d/postgresql1
vim /etc/conf.d/postgresql1
ln -s /etc/rc.d/postgresql /etc/rc.d/postgresql1

However, this is currently impossible, since the name of /etc/conf.d/postgresql is hardcoded into /etc/rc.d/postgresql. You would have to copy the whole rc.d script to achieve the same goal. And you would have to update the copy on each change to the original (caused by postgresql updates). :-(

And there are *many* similar cases. $0 could save a lot of maintenance in these non-standard scenarios (multiple mail servers, multiple DBMSs, ...).
This task depends upon

Closed by  Tom Gundersen (tomegun)
Tuesday, 08 May 2012, 12:27 GMT
Reason for closing:  Deferred
Comment by Tom Gundersen (tomegun) - Tuesday, 08 May 2012, 12:27 GMT
Sorry for no reply to this.

I won't work on this FS myself, but if anyone would post patches to arch-projects@archlinux.org we'll consider them, and if they are not too intrusive or cause regressions I'm sure they'd be accepted.

Loading...