Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F170086125
D452.id774.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D452.id774.diff
View Options
Index: etc/rc.d/sshd
===================================================================
--- etc/rc.d/sshd
+++ etc/rc.d/sshd
@@ -10,6 +10,7 @@
. /etc/rc.subr
name="sshd"
+desc="Secure Shell Daemon"
rcvar="sshd_enable"
command="/usr/sbin/${name}"
keygen_cmd="sshd_keygen"
Index: etc/rc.subr
===================================================================
--- etc/rc.subr
+++ etc/rc.subr
@@ -802,6 +802,10 @@
#
# enabled Return true if the service is enabled.
#
+# describe Show the service's description
+#
+# extracommands Show the service's extra commands
+#
# Variables available to methods, and after run_rc_command() has
# completed:
#
@@ -870,7 +874,7 @@
eval _override_command=\$${name}_program
command=${_override_command:-$command}
- _keywords="start stop restart rcvar enabled $extra_commands"
+ _keywords="start stop restart rcvar enabled describe extracommands $extra_commands"
rc_pid=
_pidcmd=
_procname=${procname:-${command}}
@@ -952,6 +956,16 @@
case "$rc_arg" in # default operations...
+ describe)
+ if [ -n "$desc" ]; then
+ echo "$desc"
+ fi
+ ;;
+
+ extracommands)
+ echo "$extra_commands"
+ ;;
+
status)
_run_rc_precmd || return 1
if [ -n "$rc_pid" ]; then
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Sep 4, 11:31 AM (18 h, 48 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
38229574
Default Alt Text
D452.id774.diff (1 KB)
Attached To
Mode
D452: Add new commands to rc(8): describe and extracommands
Attached
Detach File
Event Timeline
Log In to Comment