Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

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.

Select Badges

Select Supported Platforms

Select Status

RSS

openstack-mistral (5) Versions 0.2.3

Installs/Configures openstack-mistral

Policyfile
Berkshelf
Knife
cookbook 'openstack-mistral', '= 0.2.3', :supermarket
cookbook 'openstack-mistral', '= 0.2.3'
knife supermarket install openstack-mistral
knife supermarket download openstack-mistral
README
Dependencies
Changelog
Quality 0%

OpenStack Mistral chef cookbook

Sets up and configures Mistral Workflow Service on a chef node.

Compatibility

Use version <0.2.3 of this cookbook with chef <12.4.0.

Supported Platforms

There are no restrictions for platforms, cookbook should support major debian, fedora and rhel platforms. Tested to work on ubuntu, debian and centos.

Cookbook dependencies

Cookbook depends on other cookbooks: build-essential, python, git, mysql.

Attributes

Key Type Description Default
['openstack-mistral']['install_recipe'] String Mistral recipe used to fetch mistral. Default option will fetch mistral from git repository. 'openstack-mistral::install_source'
[‘openstack-mistral’][‘source’][‘git_url’] String Git source url. (https://github.com/stackforge/mistral)
['openstack-mistral']['source']['git_revision'] String Git branch or revision. If none is given the latest is used. nil
['openstack-mistral']['source']['git_action'] String Action for git provider. If none is given the source will be checked out. nil
['openstack-mistral']['source']['home'] String Specifies directory where source installation method will place mistral. '/opt/openstack/mistral'
['openstack-mistral']['etc_dir'] String Specifies the configuration directory where mistral configrution files are placed. '/opt/openstack/etc'
['openstack-mistral']['logfiles_mode'] String Sets log file permission for resource logfile_creates option. '0644'
['openstack-mistral']['db_initialize']['enabled'] Boolean If enabled, cookbook will try to create database for mistral. false
['openstack-mistral']['db_initialize']['superuser'] String Database user which can create databases and setup permissions. 'root'
['openstack-mistral']['db_initialize']['password'] String Password of superuser. 'ilikerandompasswords'
['openstack-mistral']['db_initialize']['allowed_hosts'] String Hosts which will be allowed to access mistral database. 'localhost'

Usage

Cookbook provides mistral resource provider which allows you to deploy mistral service, populate its configuration and start it up. Related services like: RabbitMQ or MySQL are neither installed nor configured by this cookbook.

Typical resource invocation may look like this:

mistral 'default' do
  action [ :create, :start ]
  options({
    database: {
      connection: 'mysql://mistral:changeme@127.0.0.1:3306/mistral'
    }
  })
  starts [:api, :executor, :engine]
end

In case db_initialize.enabled is provided, cookbook will try to create database mistral as well as the mistrall user identified by password changeme. However a running instance of mysql should be already in its place prior to the resource invocation.

The resource code above will bring up system service mistral. You can bring up several services by defining the resource multiple times. For names other than default the system service will be named as mistral-myname.

Mistral LWRP (mistral)

Cookbook comes with mistral resource provider which brings up mistral service or multiple mistral services. Provider uses specified install_recipe attribute if it's given to fetch mistral.

After mistral is fetched provider initializes database, creates configuration and service files and as the last step it brings up services.

mistral resource attributes

  • :bind_address - Specifies address where mistral api server listens by default 0.0.0.0.
  • :port - Specifies port of api server by default 8989.
  • :run_user - Runs service as specified user. If it's different from default user should be created manually. Default: mistral.
  • :run_group - Same as the previous for setting the group. Default: mistral.
  • :options - Use to specify options which are passed for the mistral.conf generation from the template.
  • :logfile_source - Mistral log file template cookbook path. Default: logging.conf.erb.
  • :logfile_cookbook - Cookbook of logfile template. If not given the one from this cookbook is used.
  • :logfile_options - Use to specify options to be passed for log configuration file template.
  • :logfile_creates - An array of log file paths which will pre-created by cookbook. Can be used when services are run with dropped privileges and don't have access to log directories such as /var/log.
  • :starts - Specifies an array of [:api, :engine, :executor] components to start up by mistral.

License and Authors

License:: Apache 2.0

0.2.2

Removed mysql* dependencies, since they are handled by mysql cookbook.

0.2.1

Refactored

0.1.0

Initial release of openstack-mistral

Foodcritic Metric
            

0.2.3 failed this metric

FC001: Use strings in preference to symbols to access node attributes: /tmp/cook/1901752968f0bad1ed6ccc5f/openstack-mistral/libraries/helpers.rb:67
FC001: Use strings in preference to symbols to access node attributes: /tmp/cook/1901752968f0bad1ed6ccc5f/openstack-mistral/libraries/helpers.rb:68
FC001: Use strings in preference to symbols to access node attributes: /tmp/cook/1901752968f0bad1ed6ccc5f/openstack-mistral/recipes/install_source.rb:20
FC019: Access node attributes in a consistent manner: /tmp/cook/1901752968f0bad1ed6ccc5f/openstack-mistral/libraries/helpers.rb:71
FC048: Prefer Mixlib::ShellOut: /tmp/cook/1901752968f0bad1ed6ccc5f/openstack-mistral/libraries/helpers.rb:135