head	1.26;
access;
symbols
	OPENPKG_E1_MP_HEAD:1.24
	OPENPKG_E1_MP:1.24
	OPENPKG_E1_MP_2_STABLE:1.23.8.1
	OPENPKG_E1_FP:1.23.8.1
	OPENPKG_2_STABLE_MP:1.24
	OPENPKG_2_STABLE_20061018:1.23.8.1
	OPENPKG_2_STABLE_20060622:1.23
	OPENPKG_2_STABLE:1.23.0.8
	OPENPKG_2_STABLE_BP:1.23
	OPENPKG_2_5_RELEASE:1.23
	OPENPKG_2_5_SOLID:1.23.0.6
	OPENPKG_2_5_SOLID_BP:1.23
	OPENPKG_2_4_RELEASE:1.23
	OPENPKG_2_4_SOLID:1.23.0.4
	OPENPKG_2_4_SOLID_BP:1.23
	OPENPKG_CW_FP:1.23
	OPENPKG_2_3_RELEASE:1.23
	OPENPKG_2_3_SOLID:1.23.0.2
	OPENPKG_2_3_SOLID_BP:1.23
	OPENPKG_2_2_RELEASE:1.22
	OPENPKG_2_2_SOLID:1.22.0.2
	OPENPKG_2_2_SOLID_BP:1.22
	OPENPKG_2_1_RELEASE:1.20
	OPENPKG_2_1_SOLID:1.20.0.4
	OPENPKG_2_1_SOLID_BP:1.20
	OPENPKG_2_0_RELEASE:1.20
	OPENPKG_2_0_SOLID:1.20.0.2
	OPENPKG_2_0_SOLID_BP:1.20
	OPENPKG_1_3_RELEASE:1.1.4.1
	OPENPKG_1_3_SOLID:1.1.4.1.0.2
	OPENPKG_1_3_SOLID_BP:1.1.4.1
	OPENPKG_1_STABLE_MP:1.18
	OPENPKG_1_2_RELEASE:1.1
	OPENPKG_1_2_SOLID:1.1.0.6
	OPENPKG_1_2_SOLID_BP:1.1
	OPENPKG_1_STABLE:1.1.0.4
	OPENPKG_1_STABLE_BP:1.1
	OPENPKG_1_1_RELEASE:1.1
	OPENPKG_1_1_SOLID:1.1.0.2
	OPENPKG_1_1_SOLID_BP:1.1;
locks; strict;
comment	@# @;


1.26
date	2008.12.23.10.43.13;	author rse;	state Exp;
branches;
next	1.25;
commitid	Hl7fJbUpceeKXzvt;

1.25
date	2008.12.23.10.18.59;	author rse;	state Exp;
branches;
next	1.24;
commitid	XtwFj4sny7poPzvt;

1.24
date	2006.08.25.19.19.05;	author rse;	state Exp;
branches;
next	1.23;
commitid	Tvsj1UyQ8rQ89gKr;

1.23
date	2004.12.07.19.57.39;	author rse;	state Exp;
branches
	1.23.8.1;
next	1.22;

1.22
date	2004.09.20.14.33.34;	author rse;	state Exp;
branches;
next	1.21;

1.21
date	2004.07.06.11.18.30;	author ms;	state Exp;
branches;
next	1.20;

1.20
date	2003.11.21.23.51.09;	author thl;	state Exp;
branches;
next	1.19;

1.19
date	2003.09.09.17.05.34;	author ms;	state Exp;
branches;
next	1.18;

1.18
date	2003.07.22.11.24.09;	author mlelstv;	state Exp;
branches;
next	1.17;

1.17
date	2003.07.22.08.11.10;	author rse;	state Exp;
branches;
next	1.16;

1.16
date	2003.07.21.08.40.49;	author thl;	state Exp;
branches;
next	1.15;

1.15
date	2003.07.19.17.06.27;	author rse;	state Exp;
branches;
next	1.14;

1.14
date	2003.07.17.21.35.08;	author thl;	state Exp;
branches;
next	1.13;

1.13
date	2003.07.10.07.51.04;	author rse;	state Exp;
branches;
next	1.12;

1.12
date	2003.07.07.21.54.32;	author thl;	state Exp;
branches;
next	1.11;

1.11
date	2003.06.28.15.00.27;	author rse;	state Exp;
branches;
next	1.10;

1.10
date	2003.06.24.16.23.05;	author ms;	state Exp;
branches;
next	1.9;

1.9
date	2003.06.24.13.28.35;	author thl;	state Exp;
branches;
next	1.8;

1.8
date	2003.06.24.12.08.07;	author thl;	state Exp;
branches;
next	1.7;

1.7
date	2003.04.17.14.01.56;	author ms;	state Exp;
branches;
next	1.6;

1.6
date	2003.03.12.15.34.15;	author rse;	state Exp;
branches;
next	1.5;

1.5
date	2003.03.12.15.08.22;	author mlelstv;	state Exp;
branches;
next	1.4;

1.4
date	2003.03.12.14.53.50;	author rse;	state Exp;
branches;
next	1.3;

1.3
date	2003.03.12.11.26.45;	author mlelstv;	state Exp;
branches;
next	1.2;

1.2
date	2003.02.13.14.32.38;	author ms;	state Exp;
branches;
next	1.1;

1.1
date	2002.08.12.08.04.38;	author cs;	state Exp;
branches
	1.1.4.1;
next	;

1.23.8.1
date	2006.10.16.14.56.03;	author rse;	state Exp;
branches;
next	;
commitid	iZxwRSmmWscPXUQr;

1.1.4.1
date	2003.07.24.20.50.33;	author rse;	state Exp;
branches;
next	;


desc
@@


1.26
log
@adjust paths once again
@
text
@#!@@l_prefix@@/bin/openpkg rc
##
##  rc.sasl -- Run-Commands
##

%config
    sasl_enable="$openpkg_rc_def"
    sasl_flags=""
    sasl_authmech="@@l_authmech@@"
    sasl_threads="4"
    sasl_log_prolog="true"
    sasl_log_epilog="true"
    sasl_log_numfiles="10"
    sasl_log_minsize="1M"
    sasl_log_complevel="9"

%common
    sasl_pidfile="@@l_prefix@@/var/sasl/run/saslauthd/saslauthd.pid"
    sasl_signal () {
        [ -f $sasl_pidfile ] && kill -$1 `cat $sasl_pidfile`
    }

%status -u @@l_susr@@ -o
    sasl_usable="unknown"
    sasl_active="no"
    rcService sasl enable yes && \
        sasl_signal 0 && sasl_active="yes"
    echo "sasl_enable=\"$sasl_enable\""
    echo "sasl_usable=\"$sasl_usable\""
    echo "sasl_active=\"$sasl_active\""

%start -p 400 -u @@l_susr@@
    rcService sasl enable yes || exit 0
    rcService sasl active yes && exit 0
    @@l_prefix@@/sbin/saslauthd \
        -a "${sasl_authmech}" \
        -n "${sasl_threads}" \
        ${sasl_flags}

%stop -p 600 -u @@l_susr@@
    rcService sasl enable yes || exit 0
    rcService sasl active no && exit 0
    sasl_signal TERM

%restart -u @@l_susr@@
    rcService sasl enable yes || exit 0
    rcService sasl active no && exit 0
    rc sasl stop
    sleep 2
    rc sasl start

%daily -u @@l_susr@@
    rcService sasl enable yes || exit 0
    shtool rotate -f \
        -n ${sasl_log_numfiles} -s ${sasl_log_minsize} -d \
        -z ${sasl_log_complevel} -o @@l_susr@@ -g @@l_sgrp@@ -m 600 \
        -P "${sasl_log_prolog}" \
        -E "${sasl_log_epilog}; rc sasl restart" \
        @@l_prefix@@/var/sasl/log/saslauthd.log

@


1.25
log
@major packaging cleanups and improvements
@
text
@d18 1
a18 1
    sasl_pidfile="@@l_prefix@@/var/sasl/run/saslauthd.pid"
@


1.24
log
@replace '@@l_prefix@@/lib/openpkg/bash @@l_prefix@@/etc/rc' in shebang with '@@l_prefix@@/bin/openpkg rc' to allow people who run the rc.xxx scripts directly (as executables) to leverage from the Set-UID functionality
@
text
@d8 1
d10 1
a10 1
    sasl_threads="2"
d18 1
a18 1
    sasl_pidfile="@@l_prefix@@/var/sasl/saslauthd/saslauthd.pid"
d35 4
a38 1
    @@l_prefix@@/sbin/saslauthd -a ${sasl_authmech} -n ${sasl_threads}
d56 1
a56 1
        -z ${sasl_log_complevel} -o @@l_susr@@ -g @@l_mgrp@@ -m 644 \
@


1.23
log
@remove priorities (actually inherited via cut & paste from rc.bind ;-) from packages where the default priority is fully sufficient; fix %stop priorities: they have to be 1000 minus the %start priority in order to stop a package later if it was started earlier.
@
text
@d1 1
a1 1
#!@@l_prefix@@/lib/openpkg/bash @@l_prefix@@/etc/rc
@


1.23.8.1
log
@Mass merge from CURRENT to 2-STABLE (all packages except those of JUNK class)
@
text
@d1 1
a1 1
#!@@l_prefix@@/bin/openpkg rc
@


1.22
log
@remove lonely logfile rotation comment in rc files
@
text
@d36 1
a36 1
%stop -p 400 -u @@l_susr@@
@


1.21
log
@in rc.*:%daily, restart daemons per default in shtool epilog should a logfile rotation be performed
@
text
@a49 2

    #   rotate logfile
@


1.20
log
@adjust rc priority (although limited general usefulness)
@
text
@d56 1
a56 1
        -E "${sasl_log_epilog} && rc sasl restart" \
@


1.19
log
@Implement features in #202
@
text
@d31 1
a31 1
%start -u @@l_susr@@
d36 1
a36 1
%stop -u @@l_susr@@
@


1.18
log
@%status and pidfile handling
@
text
@d33 1
d38 1
d43 2
a44 1
    sasl_signal TERM
d46 1
a46 1
    @@l_prefix@@/sbin/saslauthd -a ${sasl_authmech} -n ${sasl_threads}
d50 2
d54 1
a54 1
        -z ${sasl_log_complevel} -o @@l_rusr@@ -g @@l_rgrp@@ -m 644 \
d56 1
a56 1
        -E "${sasl_log_epilog}" \
@


1.17
log
@cleanup the priority: move 200 to 500 and because 500 is default just ommit it; fix DNS/NTP/etc. dependencies
@
text
@d16 15
d37 1
a37 3
    if [ -f @@l_prefix@@/var/sasl/saslauthd/saslauthd.pid ]; then
        kill -TERM `cat @@l_prefix@@/var/sasl/saslauthd/saslauthd.pid`
    fi
d41 1
a41 3
    if [ -f @@l_prefix@@/var/sasl/saslauthd/saslauthd.pid ]; then
        kill -TERM `cat @@l_prefix@@/var/sasl/saslauthd/saslauthd.pid`
    fi
@


1.16
log
@PR#210: shtool options space before argument
@
text
@d16 1
a16 1
%start -p 200 -u @@l_susr@@
d20 1
a20 1
%stop -p 200 -u @@l_susr@@
d26 1
a26 1
%restart -p 200 -u @@l_susr@@
@


1.15
log
@replace opXXXX with rcXXXX (PR#207)
@
text
@d37 2
a38 2
        -n${sasl_log_numfiles} -s${sasl_log_minsize} -d \
        -z${sasl_log_complevel} -o@@l_rusr@@ -g@@l_rgrp@@ -m644 \
@


1.14
log
@migrate opServiceEnabled to opService ... enable yes; use new bootstrap feature and apply opService short circuit to %env
@
text
@d17 1
a17 1
    opService sasl enable yes || exit 0
d21 1
a21 1
    opService sasl enable yes || exit 0
d27 1
a27 1
    opService sasl enable yes || exit 0
d35 1
a35 1
    opService sasl enable yes || exit 0
@


1.13
log
@use new openpkg_rc_def variable in run-command scripts for allowing the admin to change the global default for xxx_enable
@
text
@d17 1
a17 1
    opServiceEnabled sasl || exit 0
d21 1
a21 1
    opServiceEnabled sasl || exit 0
d27 1
a27 1
    opServiceEnabled sasl || exit 0
d35 1
a35 1
    opServiceEnabled sasl || exit 0
@


1.12
log
@rclint police: fix mandatory/wished trailing blank line missing
@
text
@d7 1
a7 1
    sasl_enable="yes"
@


1.11
log
@require susr; remove commenting
@
text
@d42 1
@


1.10
log
@Synchronize spec file substitution with recent rc file changes
@
text
@d34 1
a34 1
%daily -u @@l_rusr@@
a35 2

    #   rotate logfile
@


1.9
log
@add/unify log file trimming
@
text
@d34 1
a34 1
%daily -u @@l_susr@@
@


1.8
log
@cosmetics: align/fix/unify rc header comment
@
text
@d10 5
d34 10
@


1.7
log
@Fix start and stop scripts by using new pid files
@
text
@d3 1
a3 1
##  rc.sasl -- Run-Commands for Cyrus SASL
@


1.6
log
@fix rc script again; simplify auth method determination
@
text
@d17 2
a18 2
    if [ -f @@l_prefix@@/var/sasl/saslauthd/mux.pid ]; then
        kill -TERM `cat @@l_prefix@@/var/sasl/saslauthd/mux.pid`
d23 2
a24 2
    if [ -f @@l_prefix@@/var/sasl/saslauthd/mux.pid ]; then
        kill -TERM `cat @@l_prefix@@/var/sasl/saslauthd/mux.pid`
@


1.5
log
@polishing, correct sysconfdir
@
text
@d8 1
a8 5
    sasl_authmech="@@authmech@@"
    #sasl_authmech="sasldb"
    #sasl_authmech="rimap -O remote.imap.server"
    #sasl_authmech="pam"
    #sasl_authmech="ldap"
@


1.4
log
@fully work-off this package
@
text
@d8 5
a12 1
    sasl_authmech="@@l_authmech@@"
@


1.3
log
@more LDAP support
@
text
@d8 1
a8 5
    sasl_authmech="@@authmech@@"
    #sasl_authmech="sasldb"
    #sasl_authmech="rimap -O remote.imap.server"
    #sasl_authmech="pam"
    #sasl_authmech="ldap"
@


1.2
log
@Modernize rc file to current standards and choose correct auth method for platform
@
text
@d9 5
a13 1
    sasl_threads="5"
@


1.1
log
@added rc.sasl script to run saslauthd and fixed another bdb issue
@
text
@d11 8
a18 3
%start -p 200 -u root
    if opServiceEnabled sasl; then
        @@l_prefix@@/sbin/saslauthd -a ${sasl_authmech} -n ${sasl_threads}
d21 4
a24 5
%stop -p 200 -u root
    if opServiceEnabled sasl; then
        if [ -f @@l_prefix@@/var/sasl/saslauthd/mux.pid ]; then
            kill -TERM `cat @@l_prefix@@/var/sasl/saslauthd/mux.pid`
        fi
d26 2
@


1.1.4.1
log
@mass Merge-From-CURRENT (MFC) in preparation for OpenPKG 1.3 [class PLUS only]
@
text
@d3 1
a3 1
##  rc.sasl -- Run-Commands
d7 15
a21 46
    sasl_enable="$openpkg_rc_def"
    sasl_authmech="@@l_authmech@@"
    sasl_threads="2"
    sasl_log_prolog="true"
    sasl_log_epilog="true"
    sasl_log_numfiles="10"
    sasl_log_minsize="1M"
    sasl_log_complevel="9"

%common
    sasl_pidfile="@@l_prefix@@/var/sasl/saslauthd/saslauthd.pid"
    sasl_signal () {
        [ -f $sasl_pidfile ] && kill -$1 `cat $sasl_pidfile`
    }

%status -u @@l_susr@@ -o
    sasl_usable="unknown"
    sasl_active="no"
    rcService sasl enable yes && \
        sasl_signal 0 && sasl_active="yes"
    echo "sasl_enable=\"$sasl_enable\""
    echo "sasl_usable=\"$sasl_usable\""
    echo "sasl_active=\"$sasl_active\""

%start -u @@l_susr@@
    rcService sasl enable yes || exit 0
    @@l_prefix@@/sbin/saslauthd -a ${sasl_authmech} -n ${sasl_threads}

%stop -u @@l_susr@@
    rcService sasl enable yes || exit 0
    sasl_signal TERM

%restart -u @@l_susr@@
    rcService sasl enable yes || exit 0
    sasl_signal TERM
    sleep 2
    @@l_prefix@@/sbin/saslauthd -a ${sasl_authmech} -n ${sasl_threads}

%daily -u @@l_susr@@
    rcService sasl enable yes || exit 0
    shtool rotate -f \
        -n ${sasl_log_numfiles} -s ${sasl_log_minsize} -d \
        -z ${sasl_log_complevel} -o @@l_rusr@@ -g @@l_rgrp@@ -m 644 \
        -P "${sasl_log_prolog}" \
        -E "${sasl_log_epilog}" \
        @@l_prefix@@/var/sasl/log/saslauthd.log
@


