Very simple cookbook that sets up global CustomLog and Logformat directives for apache2.
This will set a customlog that applies to all vhosts that don't define their own CustomLog, as well as some LogFormat directives that can be reused by CustomLog directives in vhost configurations.
Replaces apache's other-vhosts-access-log configuration file.
ubuntu, debian, possibly other unices (untested)
Key | Type | Description | Default |
---|---|---|---|
['apache2-global-customlog']['location'] | String | Default location to log to (file or pipe) | /var/log/apache2/other-vhosts-access.log |
['apache2-global-customlog']['format'] | String | Log format for the customlog (format string or alias) | common |
['apache2-global-customlog']['log-formats'] | Hash | Log formats to define ("alias": "format") - *Note:* Quotes must be escaped in format. | {} |
Include apache2-global-customlog
in your node's run_list
:
{
"run_list": [
"recipe[apache2-global-customlog::default]"
]
}
Depends on the apache2 cookbook.
- Fork the repository on Github
- Create a named feature branch (i.e.
add-new-recipe
) - Write your change
- Write tests for your change (if applicable)
- Run the tests, ensuring they all pass
- Submit a Pull Request
Author:: Simon Detheridge ([email protected])