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14.0
- 0.13.1
- 0.13.0
- 0.12.1
- 0.11.3
- 0.11.2
- 0.11.1
- 0.11.0
- 0.10.1
- 0.10.0
- 0.9.1
- 0.9.0
- 0.8.1
- 0.8.0
- 0.7.0
- 0.6.0
- 0.5.0
Primitives for managing Chef products and packages
cookbook 'chef-ingredient', '= 2.3.0', :supermarket
knife supermarket install chef-ingredient
knife supermarket download chef-ingredient
chef-ingredient Cookbook
This cookbook provides primitives - helpers and resources - to manage Chef Software, Inc.'s products and add-ons including, but not limited to:
- Chef Server 12
- Chef Analytics
- Chef Automate
- Chef Push
- Supermarket
This cookbook also provides primitives for building and managing your Chef infrastructure.
It will perform component installation and configuration. It provides no recipes. Instead, wrapper cookbooks should be created using the resources that this cookbook provides.
Requirements
Platforms
- Ubuntu 14.04, 16.04
- Debian 7/8/9
- CentOS/RHEL 6, 7
- openSUSE
- Amazon Linux
Chef
- Chef 12.7+
Cookbooks
- none
Chef Product Resources
chef_ingredient
A "chef ingredient" is the core package itself, or products or add-on components published by Chef Software, Inc. This resource manages the installation, configuration, and running the ctl reconfigure
of individual packages.
By default, chef_ingredient
will install using the packages.chef.io
stable repository depending on the platform. However, it can be configured to use a custom repository by setting the node['chef-ingredient']['custom-repo-recipe']
attribute (nil by default).
Actions
-
install
- (default) Configures the package repository and installs the specified package. -
upgrade
- Upgrades the specified package. -
uninstall
- Uninstalls the specified package. -
remove
- Alias for uninstall -
reconfigure
- Performs thectl reconfigure
command for the package.
Properties
-
product_name
- The product name. See the PRODUCT_MATRIX.md. For example,chef-server
,analytics
,delivery
,manage
, etc. -
config
- content that will be added to the configuration file of the given product. -
ctl_command
- The "ctl" command, e.g.,chef-server-ctl
. This should be automatically detected by the library helper methodchef_ctl_command
, but may need to be specified if something changes, like a new add-on is made available. -
options
- Options passed to thepackage
resource used for installation. -
version
- Package version to install. Can be specified in various semver-alike ways:12.0.4
,12.0.3-rc.3
, and also:latest
/'latest'
. Do not use this property when specifyingpackage_source
. -
channel
- Channel to install the products from. It can be:stable
,:current
or:unstable
. -
package_source
- Full path to a location where the package is located. If present, this file is used for installing the package. -
timeout
- The amount of time (in seconds) to wait to fetch the installer before timing out. Default timeout of the Chef package resource is900
seconds. -
accept_license
- A boolean value that specifies if license should be accepted if it is asked for duringreconfigure
action. This option is applicable to only these products: manage, analytics, reporting and compliance. -
platform
- Override the auto-detected platform for which package to install. -
platform_version
- Override the auto-detected platform version for which package to install. -
architecture
- Override the auto-detected architecture for which package to install. -
platform_version_compatibility_mode
- Find closest matching package when platform auto-detection does not find an exact package match in the repository.
omnibus_service
Manages a sub-service within the context of a Chef product package. For example the rabbitmq
service that is run for the Chef Server.
Actions
This delegates to the ctl command the service management command specified in the action. Not all the service management commands are supported, however, as not all of them would make sense when used in a recipe. This resource is primarily used for sending or receiving notifications. See the example section.
Properties
-
service_name
- The name of the service to manage. Specify this likeproduct_name/service
, for example,chef-server/rabbitmq
. -
ctl_command
- The "ctl" command, e.g.chef-server-ctl
. This should be automatically detected by the library helper methodchef_ctl_command
, but may need to be specified if something changes, like a new add-on is made available.
ingredient_config
Makes it easy to create update configuration files of each Chef product. It uses the default locations for each product.
Actions
-
render
- (default) Creates the configuration file using the options passed in viaadd
action orconfig
attribute ofchef_ingredient
resource. -
add
- Adds theconfig
attribute contents to the data collection. Must run:render
action to generate the file.
Properties
-
product_name
- The product name. See the PRODUCT_MATRIX.md. For example,chef-server
,analytics
,delivery
,manage
, etc. -
config
- Content that will be added to the configuration file of the given product. -
sensitive
- Set to mask the config contents in logs. Use when you config contains information like passwords or secrets.
Examples
We may need to restart the RabbitMQ service on the Chef Server, for example when adding configuration for Chef Analytics.
template '/etc/opscode/chef-server.rb' do notifies :restart, 'omnibus_service[chef-server-core/rabbitmq]' end omnibus_service 'chef-server-core/rabbitmq' do action :nothing end
To install Chef Server using some custom configuration options:
chef_ingredient "chef-server" do config <<-EOS api_fqdn "#{node["fqdn"]}" ip_version "ipv6" notification_email "#{node["chef_admin"]}" nginx["ssl_protocols"] = "TLSv1 TLSv1.1 TLSv1.2" EOS action :install end ingredient_config "chef-server" do notifies :reconfigure, "chef_ingredient[chef-server]" end
To install or upgrade latest version of Chef Client on your nodes:
chef_ingredient "chef" do action :upgrade version :latest end
To install an add-on of Chef Server from :current
channel:
chef_ingredient 'chef-server' do channel :stable action :install end chef_ingredient 'analytics' do channel :current action :install end
Chef Infrastructure Resources
General Properties
These properties exist for all infrastructure resources
-
name
- A name for the resource. -
channel
- The channel from our package repository to install. Most of the time you want stable. -
version
- The version of Automate you want to install. -
config
- The configuration that will be written to the appropriate configuration file for the product. -
accept_license
- Do you accept Chef's license agreements. -
platform
- Use only if you need to over-ride the default platform. -
platform_version
- Use only if you need to over-ride the default platform.
chef_automate
Installs Chef Automate.
Properties
-
enterprise
- The Enterprise to create in Automate -
license
- we recommend using the chef_file resource -
chef_user
- The user you will connect to the Chef server as -
chef_user_pem
- The private key of the above Chef user -
validation_pem
- The validator key of the Chef org we're connecting to -
builder_pem
- The private key of the build nodes
chef_backend
Properties
-
bootstrap_node
- The node we'll bootstrap secrets with. -
publish_address
- node['ipaddress'] | The address you want Chef-Backend to listen on. -
chef_backend_secrets
- A location where your secrets are | we recommend using the chef_file resource. -
chef_backend_secrets_user
- The user that owns the file created by thechef_backend_secrets
attribute -
chef_backend_secrets_group
- The group that owns the file created by thechef_backend_secrets
attribute
chef_org
Properties
-
org
- The short name of the org. -
org_full_name
- The full name of the org you want to create. -
admins
- An array of admins for the org. -
users
- An array of users for the org. -
remove_users
- An array of users to remove from the org. -
key_path
- Where to store the validator key that is created with the org.
chef_user
-
username
- The username of the user. -
first_name
- The first name of the user. -
last_name
- The last name of the user. -
email
- The users e-mail. -
password
- The users password. -
key_path
- Where to store the users private key that is created with the user. -
serveradmin
- Is the user a serveradmin?
chef_client
-
node_name
- The name of the node. -
version
- The version of chef-client to install. -
chefdk
- Do you want to install chefdk? -
chef_server_url
- What is the Chef server URL to connect to. -
ssl_verify
- Validate ssl certificates? -
log_location
- Where to log. -
log_level
- Log level. -
config
- Any configuration for client.rb. -
run_list
- The clients runlist. -
environment
- Which Chef Environment the client belongs to. -
validation_pem
- The validation pem to validate with. -
validation_client_name
- The validation client name. -
tags
- Any tags for the node. -
interval
- The interval to run chef-client on. -
splay
- The randomization to add to the interval. -
data_collector_token
- The data collector token to talk to Visibility. -
data_collector_url
- The Visibility URL to send data.
chef_file
-
filename
- The name of the resource. -
source
- The source of the file. -
user
- The owner of the file. -
group
- The group owner of the file. -
mode
- The mode for the file.
chef_server
-
addons
- A set of add-ons to install with the Chef Server. -
data_collector_token
- The data collector token to authenticate with Chef Visiblity. -
data_collector_url
- The URL to connect to Visibility.
chef_supermarket
-
chef_server_url
- The Chef server's URL. -
chef_oauth2_app_id
- The oauth2 app id from the Chef server. -
chef_oauth2_secret
- The oauth2 secret from the Chef server. -
chef_oauth2_verify_ssl
- Whether to validate SSL certificates.
workflow_builder
-
pj_version
- The version of Push-Jobs to install. -
chef_user
- The Chef user to authenticate with the Chef Server. -
chef_user_pem
- The private key of the Chef user to authenticate with the Chef Server. -
builder_pem
- The builder users private key to communicate with Chef Automate. -
chef_fqdn
- The FQDN of the Chef server. -
automate_fqdn
- The FQDN of the automate server. -
supermarket_fqdn
- The FQDN of the Supermarket server. -
job_dispatch_version
- Which job dispatch version to use. V1 is push-jobs, V2 is SSH runners. -
automate_user
- What is the Automate user we're connecting to Automate as. -
automate_password
- The password for the user above. -
automate_enterprise
- The Enterprise to connect to. -
chef_config_path
- The config path for chef-client.
License & Authors
- Author: Joshua Timberman joshua@chef.io
- Author: Serdar Sutay serdar@chef.io
- Author: Patrick Wright patrick@chef.io
- Author: Nathan Cerny ncerny@chef.io
- Author: Andy Dufour adufour@chef.io
- Author: Brandon Raabe brandon.raabe@newcontext.com
- Author: Jeremy J. Miller jm@chef.io
- Author: Josh Hudson jhudson@chef.io
- Author: Stephen Lauck lauck@chef.io
- Copyright (C) 2014-2017, Chef Software Inc. legal@chef.io
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.
Dependent cookbooks
This cookbook has no specified dependencies.
Contingent cookbooks
chef-ingredient Cookbook CHANGELOG
This file is used to list changes made in each version of the chef-ingredient cookbook.
2.3.0 (2018-02-15)
- Multiple fixes for Automate and Workflow Builder resources.
- Fix permissions on chef-backend-secrets.json and provide new properties for modifying the permissions
- Remove Chefspec matchers that are no longer necessary
2.2.1 (2018-01-12)
- Resolve chef_org full name truncation issue (#215)
2.2.0 (2017-11-30)
- Resolve multiple issues with the custom resources in various Chef 12 releases by requiring Chef 12.7 or later and removing the usage of class_eval on the action_classes
- Restored compatibility with Amazon Linux on Chef 13 and added testing
- Removed unnecessary default_actions in the custom custom resources
- Resolved FC108 warnings by removing redundant :name name_properties from the custom resources
2.1.11 (2017-11-13)
- Fixed pathing for etc and .chef directories for dbuild in wf_builder
2.1.10 (2017-10-23)
- Required for chef_server cookbook (#202)
2.1.9 (2017-10-11)
- Multiple fixes for Automate and Workflow Builder resources
- Honor sensitive property when set on high level resources
- Fix chef_server resource to run without configured addons
2.1.8 (2017-08-23)
- Fix permissions on automate keys and license.
2.1.7 (2017-08-11)
- Fix remove_users to use new_resource instead of current_resource.
2.1.6 (2017-08-10)
- fix chef_org resource deprecation warnings
- RHEL 5 and 6 package manager support (RHEL 5 is not officially supported)
2.1.5 (2017-07-31)
- Update the client resource to properly source the client.rb template
- Add a log warning if the default recipe is included on a run_list
- Added supported platforms to the metadata for Supermarket
2.1.4 (2017-07-27)
- Use default package provider on RHEL instead of RPM; fixes #181
- Resolve CHEF-19 deprecation warnings (#184)
2.1.3 (2017-06-29)
- Pin mixlib-install
~> 3.3
2.1.2 (2017-06-03)
- Fix normalization of auto-detected and set architectures
2.1.1 (2017-05-22)
- Revert platform remapping and platform version truncation changes.
-
chef_ingredient
propertiesplatform
,platform_version
,architecture
default to auto-detected value when not set.
2.1.0 (2017-05-18)
- Add initial chef infrastructure resources and contributors from chef_stack project
- Add Ohai attributes as defaults to
chef_ingredient
resource propertiesplatform
,platform_version
, andarchitecture
- Add platform remapping and platform version truncation fixes to align with Chef Software Inc's software distribution systems
2.0.5 (2017-04-24)
- #155 Workaround chef_ingredient timeout property on Windows (windows_package timeout property currently broken in Chef)
- #158 Remove #check_deprecated_properties logic (handled by mixlib-install)
- Allow chef_ingredient action :upgrade on Windows
2.0.4 (2017-04-13)
- Ensure mixlib-install
~> 3.2
is installed
2.0.3 (2017-04-13)
- Normalize architectures detected by ohai before mixlib-install validation
2.0.2 (2017-04-11)
- Update resources to support Chef 12.5 and 12.6
2.0.1 (2017-03-28)
- Update DefaultHandler and OmnitruckHandler to use a global constant lookup. In some environments, not doing so caused a naming conflict with the dynamically generated ChefIngredient DSL resource class.
2.0.0 (2017-03-24)
- Remove
chef_server_ingredient
resource shim - Update mixlib-install to major version 3
-
platform_version_compatibility_mode
property no longer has a default value - If no matching artifacts are found a
Mixlib::Install::Backend::ArtifactsNotFound
exception is raised instead aRuntimeError
-
- All resources have been converted to custom resources
1.1.0 (2017-03-01)
- Test with local delivery and not Rake
- Remove sensitive property for Chef 13 compatibility as this properly is provided by chef-client now for us by any resource and doesn't need to be defined
- Test in Travis CI with kitchen-dokken and convert tests to InSpec
1.0.1 (2017-02-22)
- Testing cleanup for Chef 13 compatibility and testing on the latest platforms
1.0.0 (2017-02-15)
- Require Chef 12.5+ and remove compat_resource dependency
- Use mixlib-install >= 2.1.12 - this brings in an important fix for the
delivery
->automate
package rename. See the Discourse announcement for details on the rename
0.21.4 (2017-02-13)
- Add properties to override the platform details of a
chef_ingredient
product to install
0.21.3 (2017-02-02)
- Add timeout to package resource created by configure_from_source_package
0.21.2 (2016-10-26)
- Fix issue when failed package installs using OmnitruckHandler would not raise a converge error on subsequent runs
0.21.1 (2016-10-25)
- Update SUSE platform to use DefaultHandler
0.21.0 (2016-09-26)
- Update mixlib-install to version 2.0 (PackageRouter support)
0.20.0 (2016-09-08)
- Remove extraneous converge_by that caused downloads to show as converged on every run
- Use compat_resource cookbook to add support for Chef 12.1-12.4
- Use apt_update resource vs. the apt cookbook in the test cookbook
- Update Travis CI testing to use our standard Rakefile and cookstyle for ruby linting.
- Fix chefspec / foodcritic / test kitchen failures
- Swap the Policyfile for a Berksfile
- Remove unnecessary action and default_action properties from the custom resources
v0.19.0
- Remove delivery-cli examples and tests (we now shipit with ChefDK)
- Set version constraint to ~> 1.1 for installing mixlib-install from Rubygems
v0.18.5
v0.18.4
- Add
platform_version_compatibility_mode
property tochef_ingredient
which makes chef-ingredient select packages built for earlier version of a platform during install when a package does not exist for the current platform version.
v0.18.3
- Add
accept_license
property tochef_ingredient
which can accept license for Chef products when applicable.
v0.18.2
- Set version constraint to ~> 1.0 for installing mixlib-install from Rubygems
v0.18.1
- Bump mixlib-install version to 1.0.6 so unstable channel artifacts won't include metadata.json files.
v0.18.0
- #85 Ability to support unstable channel for all products / platforms.
- #90 Use packages from packages.chef.io instead of package cloud & remove packagecloud repository setup.
- #91 Deprecate chef-ha, chef-marketplace, chef-sync, push-client, push-server in favor of ha, marketplace, sync, push-jobs-client, push-jobs-server.
v0.17.0
- #77 Enable installation of chef and chefdk from unstable
-
#82 Set
--force-yes
for older Debian/Ubuntu
v0.16.0
- #62 Do not assume connection to the internet, allow custom recipe for a local repository
- #75 omnitruck handler windows implementation
v0.15.0
- #66 Fix push job client and server naming
- #68 Use mixlib-install while installing / upgrading packages from omnitruck
-
#71 Convert
omnibus_service
andingredient_config
to "12.5 custom resources" - #73 Use PRODUCT_MATRIX from mixlib-install
v0.14.0
- #58 Add Chef Compliance product
v0.13.1
- #57 Content accumulator guard
v0.13.0
-
#56 Uncomment
use_inline_resources
, this is required for the providers to work properly - #55 Remove unit tests for specifically the custom resources
- #54 Clarify maintainer/support in the README
v0.12.1
- #53 Relax version constraints
v0.12.0
- Refactor
chef_ingredient
and prepare to handle install/upgrade from omnitruck - Add channel property to
chef_ingredient
- Removed installed state property
- Use
product_name
instead ofpackage_name
- Add not if to skip
ingredient_config
render ifconfig
property isn't used
v0.11.3
- Remove
resource_name
from Provider because:facepalm:
v0.11.2
- Add
repository
andmaster_token
properties tochef_server_ingredient
shim for compatibility
v0.11.1
-
#37 use
define_matchers
for ChefSpec
v0.11.0
-
#35 Add
fqdn_resolves?
method forchef-server
cookbook.
v0.10.2
- Add
:add
action toingredient_config
v0.10.1
- #30 Supermarket doesn't use supermarket.rb for configuration, it's supermarket.json
v0.10.0
v0.9.1
-
#26 Remove mode, owner, and group properties from
ingredient_config
's resources to prevent resource updates after running ctl commands that manage those file permissions.
v0.9.0
- Add sensitive property to
ingredient_config
- Use recipe DSL to set resource name
v0.8.1
- Update PRODUCT_MATRIX.md with correct updated Chef Push product names (push-server, push-client). The code was updated but not the document.
v0.8.0
-
#7 Add
ingredient_config
resource -
#10 Add upgrade action for
chef_ingredient
- Test cleanup, various rubocop fixes
v0.7.0
- #3 Allow :latest as a version
- Removes the
package_name
property from thechef_ingredient
resource, long liveproduct_name
v0.6.0
Breaking changes This version is backwards-incompatible with previous versions. We're still sub-1.0, but those who wish to use the chef_server_ingredient
resource really should pin to version 0.5.0.
- #1 Use product names instead of package names.
v0.5.0
- Major refactor and rename. It's fine, this is a new cookbook!
v0.4.0 (2015-06-11)
- Add timeout attribute to
chef_server_ingredient
- Use
declare_resource
DSL method to select local package resource - Allow specifying the repository name for the packagecloud repo
v0.3.2 (2015-04-15)
- adding proxy support for packagecloud
v0.3.1 (2015-04-09)
- Various refactoring and cleanup
v0.3.0
- Add ctl command for supermarket
v0.2.0
- Add reconfigure property to ingredient resource
v0.1.0
- Release this cookbook to Supermarket
v0.0.2
- #4: define the installed attribute
- #1, #2, use packagecloud cookbook
v0.0.1
- Initial release
Collaborator Number Metric
2.3.0 passed this metric
Contributing File Metric
2.3.0 passed this metric
Foodcritic Metric
2.3.0 failed this metric
FC109: Use platform-specific package resources instead of provider property: chef-ingredient/libraries/default_handler.rb:55
Run with Foodcritic Version 13.1.1 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
No Binaries Metric
2.3.0 passed this metric
Testing File Metric
2.3.0 passed this metric
Version Tag Metric
2.3.0 passed this metric
2.3.0 passed this metric
2.3.0 passed this metric
Foodcritic Metric
2.3.0 failed this metric
FC109: Use platform-specific package resources instead of provider property: chef-ingredient/libraries/default_handler.rb:55
Run with Foodcritic Version 13.1.1 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
No Binaries Metric
2.3.0 passed this metric
Testing File Metric
2.3.0 passed this metric
Version Tag Metric
2.3.0 passed this metric
2.3.0 failed this metric
Run with Foodcritic Version 13.1.1 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
2.3.0 passed this metric
Testing File Metric
2.3.0 passed this metric
Version Tag Metric
2.3.0 passed this metric
2.3.0 passed this metric
2.3.0 passed this metric