Skip to content
Permalink
Browse files

Test simple plugin install as part of default

- Test default simple plugin install as part of default test suite.
- Add example using the test to the documentation. Add more simple examples to the README.md, demonstrating the defaults. RE: #345
  • Loading branch information...
martinb3 committed Jul 17, 2015
1 parent ea74370 commit 0d8b627ec8cde70f44e565692364790aff040377
Showing with 33 additions and 3 deletions.
  1. +1 −1 .kitchen.yml
  2. +16 −2 README.md
  3. +16 −0 test/fixtures/cookbooks/elasticsearch_test/recipes/default_with_plugins.rb
@@ -37,7 +37,7 @@ suites:
- name: default # the normal use-case
run_list:
- recipe[java]
- recipe[elasticsearch]
- recipe[elasticsearch_test::default_with_plugins]

- name: elasticsearch_test # the override-everything use case
run_list:
@@ -23,9 +23,15 @@ Actions: `:create`, `:remove`

Creates a user and group on the system for use by elasticsearch. Here is an
example with many of the default options and default values (all options except
a resource name may be omitted):
a resource name may be omitted).

```ruby
Examples:

```
elasticsearch_user 'elasticsearch'
```

```
elasticsearch_user 'elasticsearch' do
username 'elasticsearch'
groupname 'elasticsearch'
@@ -50,6 +56,10 @@ the package or directory elasticsearch was unpacked into.

Examples:

```
elasticsearch_install 'elasticsearch'
```

```
elasticsearch_install 'my_es_installation' do
type :tarball # type of install
@@ -172,6 +182,10 @@ Actions: `:install`, `:remove`
Installs or removes a plugin to a given elasticsearch instance and plugin
directory.

```
elasticsearch_plugin 'mobz/elasticsearch-head'
```

```
elasticsearch_plugin 'mobz/elasticsearch-head' do
plugin_dir '/usr/local/awesome/elasticsearch-1.5.0/plugins'
@@ -0,0 +1,16 @@
# Encoding: utf-8
#
# Cookbook Name:: elasticsearch_test
# Recipe:: default_with_plugins
#
# This cookbook is designed to be just elasticsearch::default plus installing
# some plugins. We want to test the default plugin resource without any
# interesting overrides, but don't want to ship that as a recipe in the main
# cookbook (unlike install, configure, and service, which we do ship in the
# default cookbook).

# see README.md and test/fixtures/cookbooks for more examples!
include_recipe 'elasticsearch::default'

# by default, no plugins
elasticsearch_plugin 'mobz/elasticsearch-head'

0 comments on commit 0d8b627

Please sign in to comment.
You can’t perform that action at this time.