Per Virtualhost access logs
This example showcases how to handle separate access logs configuration, Virtualhost per Virtualhost. In this example, there are two Virtualhosts:
- one for
example.comandwww.example.com - one for
media.example.com
The first Virtualhost will output accesslogs as a text file located at /var/log/example.com-access.log
The redirection.io itself does not rotate logs, so it is up to you to configure file-based logs rotation.
The second Virtualhost will also generate access logs, but to a syslog server accessible at the address syslog-server:514, using the format rfc5424.
If requests are received for another domain name, they will be normally processed and forwarded to the backend address (backend:8080) but no access log will be saved, as the access_log node has not be defined directly under reverse_proxy.