cookbook 'ultimate_config_cookbook', '= 0.1.6'
ultimate_config_cookbook (8) Versions 0.1.6 Follow2
Installs/Configures ultimate_config_cookbook
cookbook 'ultimate_config_cookbook', '= 0.1.6', :supermarket
knife supermarket install ultimate_config_cookbook
knife supermarket download ultimate_config_cookbook
Ultimate Config Cookbook for CHEF
Ultimate Config Cookbook @ CHEF Supermarket
Supported formats:
- INI
- JSON
- YAML
- TOML
- Java Properties
Install
Knife
knife cookbook site install ultimate_config_cookbook
knife cookbook site download ultimate_config_cookbook
Policyfile
cookbook 'ultimate_config_cookbook', '~> 0.1.0', :supermarket
Berkshelf/Librarian
cookbook 'ultimate_config_cookbook', '~> 0.1.0'
Example
Datasource
Use attributes or Hash for your config.
For INI files use first level for section name and 2nd level for key=value
.
Attributes example
default['config1']['section1']['prop1'] = 'val1' default['config1']['section1']['prop2'] = 'val2' default['config1']['section2']['prop3'] = 'val3'
Hash example
config = { 'section1' => { 'prop1' => 'val1', 'prop2' => 'val2' }, 'section2' => { 'prop3' => 'val3' } }
Recipe
properties:
-
file_content
- config hash, can be a reference to attribute or just Hash, for ini the use the fist level for sections. -
action
- supported actions:- create
- edit
- create_or_edit
- delete
- replace
INI Example
ini_file '/tmp/4.ini' do file_content node.default['config1'] action :create end
JSON Example
json_file '/tmp/4.json' do file_content node.default['config1'] action :create end
YAML Example
yaml_file '/tmp/4.yaml' do file_content node.default['config1'] action :create end
TOML Example
toml_file '/tmp/4.toml' do file_content node.default['config1'] action :create end
Java Properties Example
properties_file '/tmp/4.properties' do file_content node.default['config1'] action :create end
Changelog
- 0.1.6 - Java Properties Support
- 0.1.4 - TOML Support
- 0.1.3 - YAML Support
License and Authors
The MIT License (MIT)
Copyright:: 2017, Garry Lachman
https://github.com/garrylachman/chef-ultimate-config-cookbook
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.
Dependent cookbooks
This cookbook has no specified dependencies.
Contingent cookbooks
There are no cookbooks that are contingent upon this one.
Collaborator Number Metric
0.1.6 failed this metric
Failure: Cookbook has 0 collaborators. A cookbook must have at least 2 collaborators to pass this metric.
Contributing File Metric
0.1.6 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
0.1.6 failed this metric
FC067: Ensure at least one platform supported in metadata: ultimate_config_cookbook/metadata.rb:1
Run with Foodcritic Version 12.0.1 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
License Metric
0.1.6 passed this metric
No Binaries Metric
0.1.6 passed this metric
Testing File Metric
0.1.6 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
0.1.6 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 include a tag that matches this cookbook version number
0.1.6 failed this metric
0.1.6 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
0.1.6 failed this metric
FC067: Ensure at least one platform supported in metadata: ultimate_config_cookbook/metadata.rb:1
Run with Foodcritic Version 12.0.1 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
License Metric
0.1.6 passed this metric
No Binaries Metric
0.1.6 passed this metric
Testing File Metric
0.1.6 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
0.1.6 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 include a tag that matches this cookbook version number
0.1.6 failed this metric
Run with Foodcritic Version 12.0.1 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
0.1.6 passed this metric
No Binaries Metric
0.1.6 passed this metric
Testing File Metric
0.1.6 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
0.1.6 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 include a tag that matches this cookbook version number
0.1.6 passed this metric
0.1.6 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
0.1.6 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 include a tag that matches this cookbook version number
0.1.6 failed this metric