basho-labs / riak-chef-cookbook

Chef cookbook for Riak
https://supermarket.chef.io/cookbooks/riak
94 stars 78 forks source link

riak

Cookbook Version Build Status

Description

Riak is an open source, distributed database that focuses on high availability, horizontal scalability, and predictable latency.

This repository is community supported. We both appreciate and need your contribution to keep it stable. For more on how to contribute, take a look at the contribution process.

Thank you for being part of the community! We love you for it.

Requirements

Platform Support

Cookbook Dependencies

Attributes

Package

Source

ulimit

sysctl

Java

NOTE: If node['riak']['config']['search.top_level'] is set to on then Java must be installed beforehand (either by another recipe or this one) or Riak will fail to start

NOTE: As OpenJDK isn't supported officially and Sun Java for FreeBSD is only 32bit this recipe doesn't work/isn't tested on FreeBSD.

Usage

Attributes

You may notice that some attribute names contain .top_level. This is to aid rendering special configuration settings that have other settings nested beneath them.

A quick example:

search is a setting, but it also has search.solr.start_timeout and search.solr.port beneath it:

default['riak']['config']['search.top_level'] = 'off'
default['riak']['config']['search']['solr']['start_timeout'] = '30s'
default['riak']['config']['search']['solr']['port'] = 8093

These attributes render as:

search = off
search.solr.start_timeout = 30s
search.solr.port = 8093

Installation Methods

There are several installation methods for Riak supported by this cookbook. All require that the node's run_list contain the default riak recipe.

For more precise examples, please see the .kitchen.yml file.

Package

This is the default method of installation. Ensure that node['riak']['install_method'] is set to package.

Enterprise Package

For Riak Enterprise users, installing the Enterprise package requires setting one attribute:

default['riak']['package']['enterprise_key'] = '*******'

Custom Package

If you want to install a custom package of Riak (that isn't available in your operating system's package repository), ensure that the following attributes are set appropriately:

default['riak']['install_method'] = 'custom_package'
default['riak']['package']['local']['checksum'] = '2b28aeabb21488125b7e39f768c8f3b98ac816d1a30c0d618c9f82f99e6e89d9'
default['riak']['package']['local']['url'] = 'http://s3.amazonaws.com/downloads.basho.com/riak/2.1/2.1.1/ubuntu/trusty'

NOTE: FreeBSD uses custom_package regardless.

Custom Repository

If you have a package repository setup on your operating system (that isn't Basho's) and want to install Riak from there, ensure that node['riak']['install_method'] is set to custom_repository.

NOTE: This will fail unless the package repository is configured beforehand (earlier in run_list)

Source

If you want to install Riak (and Erlang) from source, ensure that node['riak']['install_method'] is set to source.

Optional Recipes

riak::sysctl

This is an optional recipe to set sysctl tunings such that Riak will not emit warnings to the log. As other systems or cookbooks may already configure these tunings, this recipe is optional. It should be placed in the run_list before recipe['riak'] if desired.

Contributions

Basho Labs repos survive because of community contribution. Here’s how to get started.

Maintainers

You can read the full guidelines for bug reporting and code contributions on the Riak Docs. And thank you! Your contribution is incredibly important to us.

License and Authors

Copyright (c) 2015 Basho Technologies, Inc.

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.