ossp-pkg/rc/rc.example 1.1 -> 1.2
--- rc.example 2002/01/24 17:47:47 1.1
+++ rc.example 2002/01/25 16:04:41 1.2
@@ -2,11 +2,39 @@
## rc.example
##
-# Generic run commands for example daemon. #
-# Using custom symbols and identifiers. #
+# Generic run commands for example daemon. Using #
+# default symbols and conventional identifiers. #
+
+%confvars
+ sftpd_enable="yes"
+ sftpd_interpreter="/usr/bin/sh"
+ sftpd_anonymous="yes"
+ sftpd_flags=""
+
+%start -p 200 -u root
+ /usr/local/sbin/sftpd -c
+
+%stop -p 200 -u root
+ kill -TERM `cat /var/sftp/run/sftpd.pid`
+
+%reload -u root
+ kill -HUP `cat /var/sftp/run/sftpd.pid`
+
+%restart -u root
+ @stop # reference to term section
+ sleep 2
+ @start # reference to start section
+
+%status -c /usr/bin/perl
+ print STDERR "Sftpd status report";
+ for ...
+
+# Generic run commands for example daemon. Using #
+# custom symbols and unconventional identifiers. #
!confvars
sftpd_enable="yes"
+ sftpd_interpreter="/usr/bin/sh"
sftpd_anonymous="yes"
sftpd_flags=""
@@ -24,25 +52,39 @@
sleep 2
&start # reference to start section
+!status -c /usr/bin/perl
+ print STDERR "Sftpd status report";
+ for ...
+
+# Generic run commands for example daemon. Using #
+# abstract syntax and conventional identifiers. #
+
+<config>
+ <set name=sftpd_enable>"yes"</set>
+ <set name=sftpd_interpreter>"/usr/bin/sh"</set>
+ <set name=sftpd_anonymous>"yes"</set>
+ <set name=sftpd_flags>""</set>
+</config>
-# Generic run commands for example daemon. #
-# Using default symbols and identifiers. #
-
-%confvars
- sftpd_enable="yes"
- sftpd_anonymous="yes"
- sftpd_flags=""
-
-%start -p 200 -u root
+<start pri=200 user=root>
/usr/local/sbin/sftpd -c
+</start>
-%term -p 200 -u root
+<stop pri=200 user=root>
kill -TERM `cat /var/sftp/run/sftpd.pid`
+</stop>
-%hangup -u root
+<reload user=root>
kill -HUP `cat /var/sftp/run/sftpd.pid`
+</reload>
-%restart -u root
- @term # reference to term section
+<restart user=root>
+ <refer name=stop> # reference to term section
sleep 2
- @start # reference to start section
+ <refer name=start> # reference to start section
+</restart>
+
+<status pri=100 interpreter=/usr/bin/perl>
+ print STDERR "Sftpd status report";
+ for ...
+</status>
|
|