From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-963303-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id B4658139694
	for <garchives@archives.gentoo.org>; Mon, 24 Jul 2017 14:04:34 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 15027E0CCA;
	Mon, 24 Jul 2017 14:04:34 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id D552AE0CCA
	for <gentoo-commits@lists.gentoo.org>; Mon, 24 Jul 2017 14:04:33 +0000 (UTC)
Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id C3A6D341706
	for <gentoo-commits@lists.gentoo.org>; Mon, 24 Jul 2017 14:04:32 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 8F1FC74BB
	for <gentoo-commits@lists.gentoo.org>; Mon, 24 Jul 2017 14:04:31 +0000 (UTC)
From: "Brian Evans" <grknight@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Brian Evans" <grknight@gentoo.org>
Message-ID: <1500905061.d97f1c09eb25b28a65aedafa11a0c850a6438c7d.grknight@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-db/mysql-init-scripts/files/
X-VCS-Repository: repo/gentoo
X-VCS-Files: dev-db/mysql-init-scripts/files/init.d-2.2 dev-db/mysql-init-scripts/files/init.d-s6-2.2
X-VCS-Directories: dev-db/mysql-init-scripts/files/
X-VCS-Committer: grknight
X-VCS-Committer-Name: Brian Evans
X-VCS-Revision: d97f1c09eb25b28a65aedafa11a0c850a6438c7d
X-VCS-Branch: master
Date: Mon, 24 Jul 2017 14:04:31 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Archives-Salt: 1766b4ea-c461-4803-b88c-42720145d783
X-Archives-Hash: 5402d0e6c84b548ec52abb7a30da5e12

commit:     d97f1c09eb25b28a65aedafa11a0c850a6438c7d
Author:     Brian Evans <grknight <AT> gentoo <DOT> org>
AuthorDate: Mon Jul 24 14:04:21 2017 +0000
Commit:     Brian Evans <grknight <AT> gentoo <DOT> org>
CommitDate: Mon Jul 24 14:04:21 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d97f1c09

dev-db/mysql-init-scripts: Minor refinements to the 2.2 init scripts

Package-Manager: Portage-2.3.6, Repoman-2.3.3

 dev-db/mysql-init-scripts/files/init.d-2.2    | 10 +++++-----
 dev-db/mysql-init-scripts/files/init.d-s6-2.2 | 12 ++++++------
 2 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/dev-db/mysql-init-scripts/files/init.d-2.2 b/dev-db/mysql-init-scripts/files/init.d-2.2
index f798052bb37..d217744de9c 100644
--- a/dev-db/mysql-init-scripts/files/init.d-2.2
+++ b/dev-db/mysql-init-scripts/files/init.d-2.2
@@ -2,7 +2,11 @@
 # Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
-extra_commands="checkconfig bootstrap_galera"
+extra_commands="checkconfig"
+extra_stopped_commands="boostrap_galera"
+
+description_checkconfig="Verify the server's configuration"
+description_boostrap_galera="Start a new Galera cluster with this server as the initial node"
 
 depend() {
 	use net.lo
@@ -27,10 +31,6 @@ mysql_svcname() {
 stringContain() { [ -z "${2##*$1*}" ] && [ -z "$1" -o -n "$2" ]; }
 
 bootstrap_galera() {
-	if ! service_stopped ; then
-		eerror "The server cannot be running to perform this action"
-		return 1
-	fi
 	MY_ARGS="--wsrep-new-cluster ${MY_ARGS}"
 	mark_service_starting
 	if start ; then

diff --git a/dev-db/mysql-init-scripts/files/init.d-s6-2.2 b/dev-db/mysql-init-scripts/files/init.d-s6-2.2
index 6e7bce3d9f1..427061aa990 100644
--- a/dev-db/mysql-init-scripts/files/init.d-s6-2.2
+++ b/dev-db/mysql-init-scripts/files/init.d-s6-2.2
@@ -25,13 +25,9 @@ mysql_svcname() {
 stringContain() { [ -z "${2##*$1*}" ] && [ -z "$1" -o -n "$2" ]; }
 
 bootstrap_galera() {
-	if ! service_stopped ; then
-		eerror "The server cannot be running to perform this action"
-		return 1
-	fi
 	MY_ARGS="--wsrep-new-cluster ${MY_ARGS}"
 	mark_service_starting
-	if start ; then
+	if start_pre && start ; then
 		mark_service_started
 		return 0
 	else
@@ -41,7 +37,11 @@ bootstrap_galera() {
 }
 
 
-extra_commands="checkconfig boostrap_galera"
+extra_commands="checkconfig"
+extra_stopped_commands="boostrap_galera"
+
+description_checkconfig="Verify the server's configuration"
+description_boostrap_galera="Start a new Galera cluster with this server as the initial node"
 supervisor=s6
 name=$(mysql_svcname)
 s6_service_timeout_stop="$((1000*${STOP_TIMEOUT:-120}))"