starting a service if a subpackage is installed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I'd like to have a way to start fcron automatically, but only if a
subpackage is installed. I have (locally) implemented the following:

The initscripts are started automatically, but they do:

 [ -e /etc/sysconfig/fcron ] && . /etc/sysconfig/fcron
 case "$1" in
  start)
        if [ "z$FCROND_STARTUP" = 'z' ]; then
           exit 6
        fi

So if $FCROND_STARTUP is not set they won't start. Then I have package
that only contains /etc/sysconfig/fcron, called fcron-startup, with, in
/etc/sysconfig/fcron:

FCROND_STARTUP=1


This seemed like a good idea to me, however when there is no
/etc/sysconfig/fcron, /etc/init.d/fcron start is just silent.

Another possibility would be to put the initscripts in a separate
package and have them started automatically, but I preferred having them
in the main package but switched on and off.


Thoughts?

--
Pat

-- 
fedora-devel-list mailing list
fedora-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-devel-list

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux