cookbook 'confd', '~> 1.1.2', :supermarket
confd (11) Versions 1.1.2 Follow0
Application cookbook which installs and configures confd.
cookbook 'confd', '~> 1.1.2'
knife supermarket install confd
knife supermarket download confd
confd-cookbook
Application cookbook which installs and configures confd.
It is often the case that application configuration files must be dynamically generated, distributed to a set of machines and a service must be kicked to reload the changes. This faculty can be made to work with Chef, but using confd offers the ability for an immediate configuration change and subsequent bounce of a service across your fleet.
Basic Usage
The default recipe writes a basic configuration out for confd using
node attributes that can be modified by changing any of the keys and
values in the node['confd']['config']
hash. If the configuration
changes on disk Chef will kick the confd service which is running
as a service.
The [confd_service custom resource](libraries/confd_service.rb) provides basic capabilities for a binary or a package installation. By default the binary is downloaded and installed from the confd GitHub project's release page.
Advanced Usage
There are two additional custom resources which provide the means for writing out confd templates and executing confd ad-hoc instead of as a service. The former custom resource assumes that confd has been installed separately as only the service resource performs the actual package or binary installation.
The confd-iptables cookbook provides an excellent example of advanced usage of the custom resource for writing out confd templates. An example of using that custom resource can be seen below, but make sure to take a look at the confd-iptables cookbook default recipe for the latest.
confd_template '/etc/iptables/confd' do
template_source node['confd-iptables']['template_source']
prefix node['confd-iptables']['prefix']
keys node.tags.map { |t| "/groups/#{t}" }
check_command "/sbin/iptables-restore -n -t < #{path}"
reload_command "/sbin/iptables-restore -n < #{path}"
notifies :restart, 'confd_service[confd]', :delayed
end
Change Log
All notable changes to this project will be documented in this file. This project adheres to Semantic Versioning.
Unreleased
1.1.1
- Fixes issue where upgrade doesn't restart service.
1.1.0
- Removes dependency on the SELinux cookbook.
1.0.8
Bug Fixes
- Fixes incorrect default options in template resource.
- Fixes path to template resource file for configuration.
1.0.4
Bug Fixes
- Squashes several issues converging and testing the confd-iptables cookbook.
1.0.0
Features
- Resource for managing confd templates and configurations.
- Resource for executing confd command.
- Resource for running confd as a service.
Collaborator Number Metric
1.1.2 passed this metric
Contributing File Metric
1.1.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Foodcritic Metric
1.1.2 passed this metric
No Binaries Metric
1.1.2 passed this metric
Publish Metric
1.1.2 passed this metric
Supported Platforms Metric
1.1.2 passed this metric
Testing File Metric
1.1.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
1.1.2 passed this metric
1.1.2 passed this metric
1.1.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Foodcritic Metric
1.1.2 passed this metric
No Binaries Metric
1.1.2 passed this metric
Publish Metric
1.1.2 passed this metric
Supported Platforms Metric
1.1.2 passed this metric
Testing File Metric
1.1.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
1.1.2 passed this metric
1.1.2 passed this metric
1.1.2 passed this metric
Publish Metric
1.1.2 passed this metric
Supported Platforms Metric
1.1.2 passed this metric
Testing File Metric
1.1.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
1.1.2 passed this metric
1.1.2 passed this metric
1.1.2 passed this metric
Testing File Metric
1.1.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
1.1.2 passed this metric
1.1.2 failed this metric
1.1.2 passed this metric