public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: www-servers/lighttpd/files/
@ 2015-09-02 17:19 Markos Chandras
  0 siblings, 0 replies; 4+ messages in thread
From: Markos Chandras @ 2015-09-02 17:19 UTC (permalink / raw
  To: gentoo-commits

commit:     8414107dc7f3df35ab6c2fa0cddd40463fdc639a
Author:     Markos Chandras <hwoarang <AT> gentoo <DOT> org>
AuthorDate: Wed Sep  2 16:58:59 2015 +0000
Commit:     Markos Chandras <hwoarang <AT> gentoo <DOT> org>
CommitDate: Wed Sep  2 17:19:01 2015 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8414107d

www-servers/lighttpd: Improve server.pid-file detection in openrc init script. Bug #366811

Package-Manager: portage-2.2.20.1

 www-servers/lighttpd/files/lighttpd.confd | 4 ----
 www-servers/lighttpd/files/lighttpd.initd | 9 ++++++---
 2 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/www-servers/lighttpd/files/lighttpd.confd b/www-servers/lighttpd/files/lighttpd.confd
index f3afb07..c7733de 100644
--- a/www-servers/lighttpd/files/lighttpd.confd
+++ b/www-servers/lighttpd/files/lighttpd.confd
@@ -6,7 +6,3 @@
 
 # Location of the lighttpd configuration file
 LIGHTTPD_CONF="/etc/lighttpd/lighttpd.conf"
-
-# Location of the lighttpd pid file
-LIGHTTPD_PID="$(/usr/bin/awk '/^server.pid-file/{s=$3};{sub("\"","",s)};END{print s}' ${LIGHTTPD_CONF})"
-

diff --git a/www-servers/lighttpd/files/lighttpd.initd b/www-servers/lighttpd/files/lighttpd.initd
index 23c0983..8abe3ba 100644
--- a/www-servers/lighttpd/files/lighttpd.initd
+++ b/www-servers/lighttpd/files/lighttpd.initd
@@ -5,6 +5,8 @@
 
 extra_started_commands="reload graceful"
 
+LIGHTTPD_PID="$($(which lighttpd) -pf ${LIGHTTPD_CONF} | grep pid | cut -d '=' -f 2 | tr -d \\\" | tr -d [:space:])"
+
 depend() {
 	need net
 	use mysql logger spawn-fcgi ldap slapd netmount dns
@@ -19,9 +21,10 @@ checkconfig() {
 	fi
 
 	if [ -z "${LIGHTTPD_PID}" ] ; then
-		ewarn "server.pid-file variable in ${LIGHTTPD_CONF}"
-		ewarn "is not set. Falling back to lighttpd.pid"
-		LIGHTTPD_PID="/run/lighttpd.pid"
+		eerror "server.pid-file variable in ${LIGHTTPD_CONF}"
+		eerror "is not set. Please set this variable properly"
+		eerror "and try again"
+		return 1
 	fi
 	/usr/sbin/lighttpd -t -f ${LIGHTTPD_CONF} >/dev/null
 }


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: www-servers/lighttpd/files/
@ 2016-05-18  6:42 Austin English
  0 siblings, 0 replies; 4+ messages in thread
From: Austin English @ 2016-05-18  6:42 UTC (permalink / raw
  To: gentoo-commits

commit:     b86a1316899a4723231f5385c747e7c6484f497c
Author:     Austin English <wizardedit <AT> gentoo <DOT> org>
AuthorDate: Wed May 18 06:35:19 2016 +0000
Commit:     Austin English <wizardedit <AT> gentoo <DOT> org>
CommitDate: Wed May 18 06:38:34 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b86a1316

www-servers/lighttpd: use #!/sbin/openrc-run instead of #!/sbin/runscript

 www-servers/lighttpd/files/lighttpd.initd | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/www-servers/lighttpd/files/lighttpd.initd b/www-servers/lighttpd/files/lighttpd.initd
index 8abe3ba..04dd8cc 100644
--- a/www-servers/lighttpd/files/lighttpd.initd
+++ b/www-servers/lighttpd/files/lighttpd.initd
@@ -1,4 +1,4 @@
-#!/sbin/runscript
+#!/sbin/openrc-run
 # Copyright 1999-2013 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: www-servers/lighttpd/files/
@ 2016-09-12  9:37 Daniel Campbell
  0 siblings, 0 replies; 4+ messages in thread
From: Daniel Campbell @ 2016-09-12  9:37 UTC (permalink / raw
  To: gentoo-commits

commit:     0db692284d2789ec6fa2ca82d630bd825f8a7f01
Author:     Daniel Campbell <zlg <AT> gentoo <DOT> org>
AuthorDate: Mon Sep 12 09:37:08 2016 +0000
Commit:     Daniel Campbell <zlg <AT> gentoo <DOT> org>
CommitDate: Mon Sep 12 09:37:08 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0db69228

www-servers/lighttpd: Fix #454366, own user/group

Adds support in the initd script for LIGHTTPD_USER and LIGHTTPD_GROUP,
which are gleaned from the lighttpd.conf file's relevant variables.

Thanks Eugene Rosenzweig

Gentoo-Bug: #454366
Gentoo-Bug-URL: https://bugs.gentoo.org/454366

Package-Manager: portage-2.3.0

 www-servers/lighttpd/files/lighttpd.initd | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/www-servers/lighttpd/files/lighttpd.initd b/www-servers/lighttpd/files/lighttpd.initd
index 04dd8cc..e345f72 100644
--- a/www-servers/lighttpd/files/lighttpd.initd
+++ b/www-servers/lighttpd/files/lighttpd.initd
@@ -1,5 +1,5 @@
 #!/sbin/openrc-run
-# Copyright 1999-2013 Gentoo Foundation
+# Copyright 1999-2016 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -31,7 +31,11 @@ checkconfig() {
 
 start() {
 	checkconfig || return 1
-	checkpath -d -q -m 0750 -o lighttpd:lighttpd /run/lighttpd/
+	# Glean lighttpd's credentials from the configuration file
+	# Fixes bug 454366
+	LIGHTTPD_USER="$(awk '/^server.username/{s=$3};{sub("\"","",s)};END{print s}' ${LIGHTTPD_CONF})"
+	LIGHTTPD_GROUP="$(awk '/^server.groupname/{s=$3};{sub("\"","",s)};END{print s}' ${LIGHTTPD_CONF})"
+	checkpath -d -q -m 0750 -o "${LIGHTTPD_USER}":"${LIGHTTPD_GROUP}" /run/lighttpd/
 
 	ebegin "Starting lighttpd"
 	start-stop-daemon --start --quiet --exec /usr/sbin/lighttpd \


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: www-servers/lighttpd/files/
@ 2016-11-20 10:18 Daniel Campbell
  0 siblings, 0 replies; 4+ messages in thread
From: Daniel Campbell @ 2016-11-20 10:18 UTC (permalink / raw
  To: gentoo-commits

commit:     258e3475e0eda930f424d3141cb3ba9fc0f87a9a
Author:     Daniel Campbell <zlg <AT> gentoo <DOT> org>
AuthorDate: Sun Nov 20 10:17:29 2016 +0000
Commit:     Daniel Campbell <zlg <AT> gentoo <DOT> org>
CommitDate: Sun Nov 20 10:17:56 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=258e3475

www-servers/lighttpd: Prevent hang in initd

Prevents a hang on read-only filesystems, fixing bug 598468

Thanks, Marek Behun!

Gentoo-Bug: 598468
Gentoo-Bug-URL: https://bugs.gentoo.org/598468

Package-Manager: portage-2.3.2

 www-servers/lighttpd/files/lighttpd.initd | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/www-servers/lighttpd/files/lighttpd.initd b/www-servers/lighttpd/files/lighttpd.initd
index e345f72..1a4fa56 100644
--- a/www-servers/lighttpd/files/lighttpd.initd
+++ b/www-servers/lighttpd/files/lighttpd.initd
@@ -5,7 +5,7 @@
 
 extra_started_commands="reload graceful"
 
-LIGHTTPD_PID="$($(which lighttpd) -pf ${LIGHTTPD_CONF} | grep pid | cut -d '=' -f 2 | tr -d \\\" | tr -d [:space:])"
+LIGHTTPD_PID="$(grep pid ${LIGHTTPD_CONF} | cut -d '=' -f 2 | tr -d \\\" | tr -d [:space:])"
 
 depend() {
 	need net


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-11-20 10:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-12  9:37 [gentoo-commits] repo/gentoo:master commit in: www-servers/lighttpd/files/ Daniel Campbell
  -- strict thread matches above, loose matches on Subject: below --
2016-11-20 10:18 Daniel Campbell
2016-05-18  6:42 Austin English
2015-09-02 17:19 Markos Chandras

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox