1 |
grknight 14/12/02 03:20:57 |
2 |
|
3 |
Modified: groonga.confd groonga.initd |
4 |
Log: |
5 |
Revbump for bug 531334 and bug 531346 |
6 |
|
7 |
(Portage version: 2.2.14/cvs/Linux x86_64, signed Manifest commit with key 67C78E1D) |
8 |
|
9 |
Revision Changes Path |
10 |
1.2 app-text/groonga/files/groonga.confd |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/groonga/files/groonga.confd?rev=1.2&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/groonga/files/groonga.confd?rev=1.2&content-type=text/plain |
14 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/groonga/files/groonga.confd?r1=1.1&r2=1.2 |
15 |
|
16 |
Index: groonga.confd |
17 |
=================================================================== |
18 |
RCS file: /var/cvsroot/gentoo-x86/app-text/groonga/files/groonga.confd,v |
19 |
retrieving revision 1.1 |
20 |
retrieving revision 1.2 |
21 |
diff -u -r1.1 -r1.2 |
22 |
--- groonga.confd 29 Nov 2014 02:30:24 -0000 1.1 |
23 |
+++ groonga.confd 2 Dec 2014 03:20:57 -0000 1.2 |
24 |
@@ -1,12 +1,9 @@ |
25 |
# Copyright 1999-2014 Gentoo Foundation |
26 |
# Distributed under the terms of the GNU General Public License v2 |
27 |
-# $Header: /var/cvsroot/gentoo-x86/app-text/groonga/files/groonga.confd,v 1.1 2014/11/29 02:30:24 grknight Exp $ |
28 |
+# $Header: /var/cvsroot/gentoo-x86/app-text/groonga/files/groonga.confd,v 1.2 2014/12/02 03:20:57 grknight Exp $ |
29 |
|
30 |
-# Default |
31 |
-#USER=groonga |
32 |
-#GROUP=groonga |
33 |
-#ADDRESS=127.0.0.1 |
34 |
-#DATABASE=/var/lib/groonga/db/db |
35 |
-#LOG_PATH=/var/log/groonga/groonga.log |
36 |
-#QUERY_LOG_PATH=/var/log/groonga/query.log |
37 |
-#PROTOCOL=gqtp |
38 |
+#GROONGA_USER=groonga |
39 |
+#GROONGA_GROUP=groonga |
40 |
+#GROONGA_PID=/run/groonga/groonga.pid |
41 |
+#CONFIG_FILE=/etc/groonga/groonga.conf |
42 |
+DATABASE=/var/lib/groonga/db |
43 |
|
44 |
|
45 |
|
46 |
1.2 app-text/groonga/files/groonga.initd |
47 |
|
48 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/groonga/files/groonga.initd?rev=1.2&view=markup |
49 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/groonga/files/groonga.initd?rev=1.2&content-type=text/plain |
50 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/groonga/files/groonga.initd?r1=1.1&r2=1.2 |
51 |
|
52 |
Index: groonga.initd |
53 |
=================================================================== |
54 |
RCS file: /var/cvsroot/gentoo-x86/app-text/groonga/files/groonga.initd,v |
55 |
retrieving revision 1.1 |
56 |
retrieving revision 1.2 |
57 |
diff -u -r1.1 -r1.2 |
58 |
--- groonga.initd 29 Nov 2014 02:30:24 -0000 1.1 |
59 |
+++ groonga.initd 2 Dec 2014 03:20:57 -0000 1.2 |
60 |
@@ -1,21 +1,21 @@ |
61 |
#!/sbin/runscript |
62 |
# Copyright 1999-2014 Gentoo Foundation |
63 |
# Distributed under the terms of the GNU General Public License v2 |
64 |
-# $Header: /var/cvsroot/gentoo-x86/app-text/groonga/files/groonga.initd,v 1.1 2014/11/29 02:30:24 grknight Exp $ |
65 |
+# $Header: /var/cvsroot/gentoo-x86/app-text/groonga/files/groonga.initd,v 1.2 2014/12/02 03:20:57 grknight Exp $ |
66 |
+ |
67 |
+command=/usr/bin/groonga |
68 |
+command_args="-d --pid-path ${GROONGA_PID:-/run/groonga/groonga.pid} --config-path=${CONFIG_FILE:-/etc/groonga/groonga.conf} ${DATABASE}" |
69 |
+pidfile="${GROONGA_PID:-/run/groonga/groonga.pid}" |
70 |
+start_stop_daemon_args="--quiet --user ${GROONGA_USER:-groonga}:${GROONGA_GROUP:-groonga}" |
71 |
|
72 |
depend() { |
73 |
use net |
74 |
} |
75 |
|
76 |
-start() { |
77 |
- ebegin "Starting groonga" |
78 |
- checkpath -d /run/groonga -o ${USER:-groonga}:${GROUP:-groonnga} |
79 |
- start-stop-daemon --start --quiet --exec /usr/sbin/groonga -- ${GROONGA_OPTS} |
80 |
- eend $? |
81 |
-} |
82 |
- |
83 |
-stop() { |
84 |
- ebegin "Stopping groonga" |
85 |
- start-stop-daemon --stop --quiet --pidfile /var/spool/groonga/groonga.pid |
86 |
- eend $? |
87 |
+start_pre() { |
88 |
+ checkpath -d /run/groonga -o ${GROONGA_USER:-groonga}:${GROONGA_GROUP:-groonga} |
89 |
+ if [ ! -e "${DATABASE}" ] ; then |
90 |
+ einfo "Creating database ${DATABASE}" |
91 |
+ su -s /bin/sh -c "/usr/bin/groonga -n ${DATABASE} quit" ${GROONGA_USER:-groonga} |
92 |
+ fi |
93 |
} |