Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can you disable apache logs for a single site using htaccess or in the Virtual Host settings?

I'm working on a web site where the client doesn't want ANY logging on the site for privacy reasons. The site will be hosted on the same Apache Web Server as a number of other websites which is why I can just turn logging off in Apache. Is there some way to disable logging for an individual site using htaccess rules or by adding something to the VirtualHost settings?

like image 805
SomethingOn Avatar asked Apr 05 '12 15:04

SomethingOn


1 Answers

The options seem to be

  1. Sending to /dev/null on *nix or C:/nul on Windows (see here)
  2. Removing the base logging directives and duplicating them in each vhost (so there is no logging on for vhosts by default)

Seems like there should be some better way to do this, but that's what I've found.

like image 166
mdjnewman Avatar answered Nov 15 '22 00:11

mdjnewman