Pete Karl II
Pete Karl II

Reputation: 4300

Can I get Nginx to log certain types of requests differently?

I want Nginx to log requests that start with /path to a certain log file. like this:

Sorry if this is vague, but I'm new to the nginx config biz. Feel free to ask questions about what I'm doing, I'll answer them the best I can.

Upvotes: 2

Views: 483

Answers (1)

Jorge Niedbalski R.
Jorge Niedbalski R.

Reputation: 604

location /foobar {
 access_log /var/log/foobar.log;
}

Upvotes: 6

Related Questions