Version information
This version is compatible with:
- Puppet Enterprise 2023.8.x, 2023.7.x, 2023.6.x, 2023.5.x, 2023.4.x, 2023.3.x, 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x
- Puppet >= 7.0.0 < 9.0.0
Start using this module
Add this module to your Puppetfile:
mod 'puppetlabs-windows_eventlog', '4.0.0'
Learn more about managing modules with a PuppetfileDocumentation
windows_eventlog
Table of Contents
- Overview
- Module Description - What is the windows_eventlog module?
- Setup - The basics of getting started with windows_eventlog
- Usage - Configuration options and additional functionality
- Reference - An under-the-hood peek at what the module is doing and how
- Limitations - OS compatibility, etc.
- Development - Guide for contributing to the module
Overview
Puppet module for managing windows event logs
Module Description
The purpose of this module is to manage each of the Windows event logs, including the size, rotation and retention
Setup
What windows_eventlog affects
- Sets registry keys to manage the event log configuration
Beginning with windows_eventlog
Manage the size of the Application log:
windows_eventlog { 'Application':
log_path => '%SystemRoot%\system32\winevt\Logs\Application.evtx',
log_size => 2048,
max_log_policy => 'overwrite',
}
Manage several custom logs under C:\Logs:
windows_eventlog { ['Custom1', 'Custom2', 'Custom3']:
log_path_template => 'C:\Logs\%%NAME%%.evtx',
}
Usage
Classes and Defined Types
Defined Type: windows_eventlog
The primary definition of this module. Manages the size and rotation policy of Windows event logs
Parameters within windows_eventlog
:
log_path
(Optional) The path to the log file that you want to manage.
log_size
The max size of the log file in bytes. Defaults to 1028
.
max_log_policy
The retention policy for the log. Defaults to 'overwrite
'.
log_path_template
(Optional) A template for log_path
, where "%%NAME%%
" will be replaced with
the log name. Defaults to '%SystemRoot%\\system32\\winevt\\Logs\\%%NAME%%.evtx
'.
Reference
Defined Types
Public Defined Types
windows_eventlog
: Manages the size and rotation policy of a Windows event log
Limitations
This module is tested on the following platforms:
- Windows 2008 R2
It is tested with the OSS version of Puppet only.
Development
Contributing
Please read CONTRIBUTING.md for full details on contributing to this project.
Transfer notice
This module was previously maintained by Vox Pupuli. It was migrated to Puppet/Perforce in 2023.
Reference
Table of Contents
Defined types
windows_eventlog
: Manage Windows Event Logs
Defined types
windows_eventlog
Manage windows event logs including the size, rotation and retention
Examples
Manage the size of the Application log:
windows_eventlog { 'Application':
log_path => '%SystemRoot%\system32\winevt\Logs\Application.evtx',
log_size => '2048',
max_log_policy => 'overwrite'
}
Manage several custom event logs under C:\Logs:
windows_eventlog { ['Custom1', 'Custom2', 'Custom3']:
log_path_template => 'C:\Logs\%%NAME%%.evtx'
}
Parameters
The following parameters are available in the windows_eventlog
defined type:
log_path
Data type: Optional[String[1]]
The path to the log file that you want to manage
Default value: undef
log_size
Data type: Integer
The max size of the log file
Default value: 1028
max_log_policy
Data type: Enum['overwrite', 'manual', 'archive']
The retention policy for the log
Default value: 'overwrite'
log_path_template
Data type: String[1]
A template for log_path, where "%%NAME%%" will be replaced with the log name
Default value: '%SystemRoot%\system32\winevt\Logs\%%NAME%%.evtx'
root_key
Data type: String[1]
The root path of the registry key of which prepends this defined type
Default value: 'HKLM\System\CurrentControlSet\Services\Eventlog'
Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
v4.0.0 - 2023-08-17
Added
Changed
- Drop Puppet 6 support #73 (bastelfreak)
- Modernize module #68 (ghoneycutt)
v3.0.0 - 2020-01-16
Added
Changed
- modulesync 2.7.0 and drop puppet 4 #51 (bastelfreak)
v2.0.2 - 2018-10-19
Added
- modulesync 2.2.0 and allow puppet 6.x #46 (bastelfreak)
- allow puppetlabs/stdlib 5.x #43 (bastelfreak)
Fixed
v2.0.1 - 2018-08-18
v2.0.0 - 2017-11-17
Added
- bump puppet version dependency to >= 4.7.1 < 6.0.0 #32 (bastelfreak)
v1.2.0 - 2017-02-11
v1.1.1 - 2016-05-08
v1.0.0 - 2015-03-22
Dependencies
- puppetlabs/stdlib (>= 8.4.0 < 10.0.0)
- puppetlabs/registry (>= 4.0.0 < 6.0.0)
Copyright (c) 2014 Liam Bennett (liamjbennett@gmail.com) Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Quality checks
We run a couple of automated scans to help you assess a module’s quality. Each module is given a score based on how well the author has formatted their code and documentation and select modules are also checked for malware using VirusTotal.
Please note, the information below is for guidance only and neither of these methods should be considered an endorsement by Puppet.
Malware scan results
The malware detection service on Puppet Forge is an automated process that identifies known malware in module releases before they’re published. It is not intended to replace your own virus scanning solution.
Learn more about malware scans- Module name:
- puppetlabs-windows_eventlog
- Module version:
- 4.0.0
- Scan initiated:
- August 17th 2023, 4:48:12
- Detections:
- 0 / 58
- Scan stats:
- 53 undetected
- 0 harmless
- 4 failures
- 1 timeouts
- 0 malicious
- 0 suspicious
- 16 unsupported
- Scan report:
- View the detailed scan report