lighttpd forum lighty > mod_status config and conditionals

Posted by Ali Kuru
on 21.03.2008 19:54
Hi,

I have updated my server recently and I noticed that my previous
configuration for the mod_status is not working anymore.

I'm using Debian and the mod_status configuration was integrated with
the main /etc/lighttpd/lighttpd.conf before the upgrade. It looks like
now, with the new version, mod_status is handling by lighty-enable-mod &
lighty-disable-mod scripts and it has its own config at
/etc/lighttpd/conf-available/10-status.conf.

After I've figured this, I've deleted the old lines from the
lighttpd.conf and moved my configuration to new 10-status.conf.
Actually, I have only one line of configuration, which serving stats for
Munin;

$HTTP["remoteip"] == "127.0.0.1" { status.status-url = "/server-status"
}

Since I don't want /server-status to be publicly available, I covered
the configuration with a conditional, which was working well before the
upgrade.

Interesting thing is, when I use only;

status.status-url = "/server-status"

without a conditional, it works (tried this both in the lighttpd.conf
and in the 10-status.conf). When I use the conditional,
"127.0.0.1/server-status" returns 404 (again, tried this both in the
lighttpd.conf and in the 10-status.conf).

Here are some details about my server;
~$ cat /etc/debian_version
lenny/sid

~$ dpkg -l|grep lighttpd
ii  lighttpd                      1.4.19-1

/etc/lighttpd/conf-available/10-status.conf
## mod_status generates the status overview of the webserver.
##
## Documentation: /usr/share/doc/lighttpd-doc/status.txt
##      http://trac.lighttpd.net/trac/wiki/Docs%3AModStatus

server.modules += ( "mod_status" )

## relative URL which is used to retrieve the status-page
$HTTP["remoteip"] == "127.0.0.1" { status.status-url = "/server-status"
}
# status.status-url = "/server-status"

## relative URL for the config page which displays the loaded modules
# status.config-url = "/server-config"

## relative URL for a plain-text page containing the internal statistics
# status.statistics-url = "/server-statistics"

## add JavaScript which allows client-side sorting for the connection
overview
## default: enable
# status.enable-sort = "disable"


My question is;
- Is this a new policy of mod_status or a bug? Or, am I doing something
wrong?
Posted by Ali Kuru
on 24.03.2008 08:09
Ali Kuru wrote:

> My question is;
> - Is this a new policy of mod_status or a bug? Or, am I doing something
> wrong?

No ideas?
Is this the wrong place?
Should I open a ticket at trac instead?
Posted by Pierre Métras (Guest)
on 13.05.2008 15:28
Ali Kuru wrote:
> 
> No ideas?
> Is this the wrong place?
> Should I open a ticket at trac instead?

I have the same behavior on Ubuntu with lighttpd 1.4.18. Seems to me to 
be a bug and you should open a ticket.
Posted by Olaf van der Spek
on 13.05.2008 19:19
Pierre Métras wrote:
> Ali Kuru wrote:
>> 
>> No ideas?
>> Is this the wrong place?
>> Should I open a ticket at trac instead?
> 
> I have the same behavior on Ubuntu with lighttpd 1.4.18. Seems to me to 
> be a bug and you should open a ticket.

There's an existing bug regarding conditionals. It's by design 
(according to Lighttpd developers) or broken (by most others).