Adoptable Cookbooks List

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

node['syslog_ng']['config']['preinclude'] - An array of files to include at the beginning of the global configuration file before any other directives

node['syslog_ng']['config']['include'] - An array of files to include in the global configuration file

node['syslog_ng']['config']['combined'] - A hash containing the global combined configuration directives, that is log entries which contain all their directives rather than referencing other source/filter/destination directives

syslog_ng::install

node['syslog_ng']['install']['remove_rsyslog'] - When set true rsyslog will be explicitly removed, otherwise it will be disabled

node['syslog_ng']['install']['copr_repo_version'] - Version to install from COPR as a float, set to current latest version which is 3.19. See czanik COPR for versions available to install.

Libraries

config

Provides a set of helper methods to generate syslog-ng configuration stanzas, due to the variety and format they can be complex to construct so most of the
heavy lifting is done by the SyslogNg::ConfigHelpers library.

install

SyslogNg::InstallHelpers.installed_version_get

Returns the current installed version as a float to be used for the version directive in the global configuration file.

SyslogNg::InstallHelpers.repo_get_packages

Returns an array of the packages to install from the relevant package manager.

SyslogNg::InstallHelpers.installed_get_packages

Returns an array of install syslog-ng packages to remove as part of an uninstall.

Usage

This cookbook contains no recipes and only provides resources to be directly used or wrapped in a wrapper cookbook.

Resources

config_global Usage

All properties are optional and by default the settings in the generated global configuration will be retrieved from node attributes, any properties can be overridden by changing the attributes, specifying a different attribute or providing a value to the relevant resource property.

filter Usage

Due to the large amount of possible combinations of Boolean operators and containers to which can be applied in a filter, this resource has a reasonably complex Hash structure and despite trying to break this as much as possible in testing, this library will very likely have some bugs in it.

In the case of the library being unable to generate a filter there is the option of giving the correctly formatted filter as a String or as an Array of String, in this case it is up to the implementer to ensure that it is a correctly formatted filter statement for syslog-ng.

install Usage

There are two installation methods available package_distro and package_copr. The COPR installation method is only available to current Redhat and Fedora (7+ and 28+) distributions but does provide up-to-date versions that aren't in the distribution repositories.

By default the resource will remove rsyslog which is the default syslog daemon on the supported distros, if this is set to false then the rsyslog service will just be disabled instead. Some package managers will remove rsyslog anyway when installing syslog-ng so even if this set to false rsyslog can still be removed.

The syslog_ng_install resource does not require a name property.

Distribution repository package installation

syslog_ng_install '' do
action :install
end

COPR repository package installation

Uninstall

log Usage

A log statement is the last part of a combination of source, filter and destination resources to create a completed log configuration with syslog-ng. Multiple source, filter and destination elements can be passed to the resource as a String Array.

The resource does not presently support embedded log statements, this will be added as a future development.

Authors

License

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.