From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 0A870138200 for ; Tue, 13 Aug 2013 17:22:20 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id DB0BCE0A94; Tue, 13 Aug 2013 17:22:16 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 5B717E0A94 for ; Tue, 13 Aug 2013 17:22:16 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 3F3CF33EB3A for ; Tue, 13 Aug 2013 17:22:15 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id C4347E5459 for ; Tue, 13 Aug 2013 17:22:13 +0000 (UTC) From: "William Hubbs" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "William Hubbs" Message-ID: <1376413963.b2f8ac9382d5dad70181ef803a37f43896f5cb91.WilliamH@OpenRC> Subject: [gentoo-commits] proj/openrc:master commit in: man/ X-VCS-Repository: proj/openrc X-VCS-Files: man/runscript.8 X-VCS-Directories: man/ X-VCS-Committer: WilliamH X-VCS-Committer-Name: William Hubbs X-VCS-Revision: b2f8ac9382d5dad70181ef803a37f43896f5cb91 X-VCS-Branch: master Date: Tue, 13 Aug 2013 17:22:13 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: fa5b1438-263d-454e-8693-7baa65bf4f94 X-Archives-Hash: a97bb5fa12d686dd69d4651cdc87eaab commit: b2f8ac9382d5dad70181ef803a37f43896f5cb91 Author: William Hubbs gmail com> AuthorDate: Tue Aug 13 17:12:43 2013 +0000 Commit: William Hubbs gentoo org> CommitDate: Tue Aug 13 17:12:43 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/openrc.git;a=commit;h=b2f8ac93 Clarify the documentation about the restart function Restart has never been able to be overridden in OpenRc, but there is a way to make your service script behave differently when restart is being executed. X-Gentoo-Bug: 480866 X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=480866 --- man/runscript.8 | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/man/runscript.8 b/man/runscript.8 index 7277546..ddce662 100644 --- a/man/runscript.8 +++ b/man/runscript.8 @@ -60,7 +60,10 @@ First we ensure that any services that depend on us are stopped. If any services that need us fail to stop then we exit with a suitable error, otherwise call the supplied stop function if it exists. .It Ar restart -Stop and start the service, including dependencies. +Stop and start the service, including dependencies. This cannot be +overridden. See the description of the RC_CMD variable below for the +method to make your service behave differently when restart is being +executed. .It Ar status Show the status of the service. The return code matches the status, with the exception of "started" returning 0 to match standard command behaviour. @@ -362,7 +365,8 @@ offset. Otherwise it is undefined. The result of `uname -s`. .It Va RC_CMD This contains the name of the command the service script is executing, such -as start, stop, restart etc. +as start, stop, restart etc. One example of using this is to make a +service script behave differently when restart is being executed. .El .Sh FILES .Pp