-
Notifications
You must be signed in to change notification settings - Fork 82
Open
Description
I want to adopt Ferron in my company (after success with my personal website), but there is one blocker: dynamic file path for access log.
The idea is that, my company website can be reach via various domains. We want to track how much traffic a domain get, so we need to separate access log per domain. For example, here is what we do in Nginx:
include includes/bot_definition.conf;
server {
server_name *.gomarkaz.com gomarkaz.com;
# Required for dynamic log file path
root /opt/Markaz/public/fake-roots/$host/;
access_log /var/log/nginx/markaz/$host/access.log combined if=$is_not_bot;
access_log /var/log/nginx/markaz/$host/bot_access.log combined if=$is_bot;
# Error log doesn't support variables
error_log /var/log/nginx/markaz/error.log;
}If the /opt/Markaz/public/fake-roots/easyuni/ folder exists, all traffics to easyuni.gomarkaz.com will be logged to /var/log/nginx/markaz/easyuni.gomarkaz.com/access.log file. The root directive is to prevent arbitrary folder from being created in /var/log/nginx/markaz/.
I would love to see Ferron supporting this use case. Thanks!
Metadata
Metadata
Assignees
Labels
No labels