Rotating Access Logs with $date_local
Igal @ getRailo.org
igal at getrailo.org
Tue Oct 28 17:18:23 UTC 2014
On 10/28/2014 10:12 AM, Francis Daly wrote:
> The thread starting at http://forum.nginx.org/read.php?2,254210 is not
> entirely dissimilar to this one. You may find useful answers there.
> The most useful is probably "don't do that"; but since you want to do
> that, you can probably use one "if" or multiple "map"s. f
Thank you for your reply.
You mentioned multiple maps but why can't it be done with a single one?
I managed to extract the year via
map $time_local $date {
~(?P<year>\d\d\d\d) $year;
}
so this is much progress, but shouldn't I be able to do something like
~(?P<day>\d\d\d)/(?P<month>\w\w\w)/(?P<year>\d\d\d\d)"
$year$month$day;
?
unfortunately that throws an error: unknown "year$month" variable
Thanks
--
Igal Sapir
Railo Core Developer
http://getRailo.org/
More information about the nginx
mailing list