Separate logs within the same server for different server names?

ST smntov at gmail.com
Thu Jun 15 11:02:09 UTC 2017


Hello,

is it possible somehow to define separate logs within the same server{}
for different server names (server_name one.org two.org;)?

access_log /var/log/nginx$server_name/access.log;
error_log /var/log/nginx$server_name/error.log;

Thank you!



More information about the nginx mailing list