-
-
Notifications
You must be signed in to change notification settings - Fork 599
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change how attributes and resource parameters work
- Node attributes and the `elasticsearch::default` recipe: 1. We're now using `node['elasticsearch'][<resource>][<param>]` and we automatically post any of those values to the corresponding resource in `elasticsearch::default`. For example, if you set `node['elasticsearch']['user']['shell']='/bin/sh'`, we will automatically call `elasticsearch_user_resource.shell '/bin/sh'`. This allows people to set as much as they want in the node attributes and still use the ::default recipe, and we'll pass it to the appropriate places. 2. We now use strings for the type of install (e.g. 'package' or 'tarball', not :package or :tarball). Also, 'tar' has been dropped as a supported value. - Installing elasticsearch 1. We now install the tarball and package files into the same locations. There's no more `/usr/local`; it's all in one place. This allows us to drop a huge part of the default values for non-package installs. You may still override the values to be `/usr/local`, we just don't give you the defaults for it. 2. We dropped the fancy logic for figuring out the requested version of Elasticsearch to be installed. You should pass it on the resource or in the recipe, but we no longer do a bunch of logic to figure out what you meant -- we favor being explicit now. 3. We delete the sample configs directory when doing a tarball installation. It was overriding the stuff in /etc and /lib. - Configuring elasticsearch 1. We've dropped the `gc_options` parameter of elasticsearch_configure, and now have `jvm.options`. We've also dropped thread_stack_size and env_options, as they aren't used in the upstream packaging as defaults anymore. We added `max_map_count` since that was added in the packaging as well. 2. Systemd support required we create `/usr/lib/systemd/system` if it didn't exist, but `/usr/lib/systemd` did exist. - Running elasticsearch 1. We now start the service by default, instead of only `:enable` but not `:start`. 2. The systemd packaging scripts don't allow the override of ES_USER or ES_GROUP env vars to take effect. We've filed an upstream bug about this. - Cookbook testing 1. Due to the new attribute handling in the recipe, we're using `::default` a lot more in our tests. Fixes #497. Fixes #512.
- Loading branch information
Showing
32 changed files
with
198 additions
and
512 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,19 @@ | ||
# elasticsearch version & install type | ||
default['elasticsearch']['version'] = '5.0.0' | ||
default['elasticsearch']['install_type'] = :package | ||
# empty settings (populate these for the elasticsearch::default recipe) | ||
# see the resources or README.md to see what you can pass here. | ||
default['elasticsearch']['user'] = {} | ||
default['elasticsearch']['install'] = {} | ||
default['elasticsearch']['configure'] = {} | ||
default['elasticsearch']['service'] = {} | ||
default['elasticsearch']['plugin'] = {} | ||
|
||
# platform_family keyed download URLs | ||
default['elasticsearch']['download_urls'] = { | ||
'debian' => 'https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-%s.deb', | ||
'rhel' => 'https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-%s.rpm', | ||
'tar' => 'https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-%s.tar.gz' | ||
'tarball' => 'https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-%s.tar.gz' | ||
} | ||
|
||
# platform_family keyed download sha256 checksums | ||
default['elasticsearch']['checksums']['5.0.0']['debian'] = '0a4f8842a1f7d7bd3015118298284383efcd4c25f9591c46bb5ab68189815268' | ||
default['elasticsearch']['checksums']['5.0.0']['rhel'] = 'fb502a9754f2162f27590125aecc6b68fa999738051d8f230c4da4ed6deb8d62' | ||
default['elasticsearch']['checksums']['5.0.0']['tar'] = 'a866534f0fa7428e980c985d712024feef1dee04709add6e360fc7b73bb1e7ae' | ||
default['elasticsearch']['checksums']['5.0.0']['tarball'] = 'a866534f0fa7428e980c985d712024feef1dee04709add6e360fc7b73bb1e7ae' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.