summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xabs/core/runit-scripts/PKGBUILD2
-rwxr-xr-xabs/core/runit-scripts/runitscripts/services/mysql/run7
-rwxr-xr-xabs/core/runit-scripts/runitscripts/services/mythbackend/run3
3 files changed, 10 insertions, 2 deletions
diff --git a/abs/core/runit-scripts/PKGBUILD b/abs/core/runit-scripts/PKGBUILD
index 581bf06..83530fe 100755
--- a/abs/core/runit-scripts/PKGBUILD
+++ b/abs/core/runit-scripts/PKGBUILD
@@ -1,6 +1,6 @@
pkgname=runit-scripts
pkgver=2.1.1
-pkgrel=77
+pkgrel=78
pkgdesc="collection of startup scripts for runit"
url="http://smarden.org/runit/"
license="BSD"
diff --git a/abs/core/runit-scripts/runitscripts/services/mysql/run b/abs/core/runit-scripts/runitscripts/services/mysql/run
index e9dc6f6..f078c87 100755
--- a/abs/core/runit-scripts/runitscripts/services/mysql/run
+++ b/abs/core/runit-scripts/runitscripts/services/mysql/run
@@ -35,5 +35,10 @@ if [ ! -d /var/run/mysqld ]; then
mkdir -p /var/run/mysqld
chown mysql /var/run/mysqld
fi
-exec /usr/bin/mysqld_safe --user=mysql &>/dev/null
+HOME=/etc/mysql/
+MYSQLADMIN='/usr/bin/mysqladmin'
+trap "$MYSQLADMIN shutdown" 0
+trap 'exit 2' 1 2 3 15
+
+/usr/bin/mysqld_safe --user=mysql & wait
diff --git a/abs/core/runit-scripts/runitscripts/services/mythbackend/run b/abs/core/runit-scripts/runitscripts/services/mythbackend/run
index 26dca04..937b267 100755
--- a/abs/core/runit-scripts/runitscripts/services/mythbackend/run
+++ b/abs/core/runit-scripts/runitscripts/services/mythbackend/run
@@ -4,6 +4,9 @@ exec 2>&1
export TERM=linux
. /etc/rc.conf
. /etc/rc.d/functions
+#wait for mysql
+/sbin/svwaitup -s 5 /service/mysql
+
#profile is here to setup LC_ALL/locale
MYTH_RUN_STATUS="1"
. /etc/profile