We use a dynamic value for access logs:
access_log /var/log/nginx/domains/$host/access.log main;
However, if the $host directory does not exist in /var/log/nginx/domains nginx fails with an error creating the access log. Is there a way to have nginx create the $host directory automatically instead of failing?
Seems like this should be default behavior?