This is the semi-official 'all-in-one' Logstash cookbook.
This cookbook is primarily a library cookbook.
While you can still use the agent
and server
recipes, they are not recommended as they are very limited in what they do.
If you are using logstash < 1.2 you might want to use the 0.6.x branch. If you are using logstash < 1.4 you might want to use the 0.7.x branch.
All of the requirements are explicitly defined in the recipes. Every effort has been made to utilize Community Cookbooks.
However if you wish to use an external ElasticSearch cluster, you will need to install that yourself and change the relevant attributes for discovery. The same applies to integration with Graphite.
This cookbook has been tested together with the following cookbooks, see the Berksfile for more details
no longer used. see Community Beaver cookbook
no longer supports installing from source.
These now do all the heavy lifting.
This will install a logstash instance. It will take defaults from attributes for most attributes.
This will create system init scripts for managing logstash instance. It will take defaults from attributes for most attributes.
experimental support for pleaserun has been added. Only native
for Ubuntu 12.04
has been thoroughly tested.
This will create logstash config files. It will take defaults from attributes for most attributes.
This will install custom grok patterns for logstash. It will take defaults from attributes for most attributes:
This will install the logstash community plugins:
This will install the ElasticSearch Curator and setup a cron job. This replaces the deprecated index_cleaner
:
We've done our best to make this intuitive and easy to use.
You should be able to override settings in any of the above places. It is recommended for readability that you set non-default options in the LWRP resource block. But do whichever makes sense to you.
There is a search helper library libraries/search.rb
which will help you search for values such as elasticsearch_ip
. see the server
recipe for an example of its usage.
$ bundle exec rake
$ kitchen converge server_ubuntu
Any and all contributions are welcome. We do ask that you test your contributions with the testing framework before you send a PR. All contributions should be made against the master branch.
Please update tests and changelist with your contributions.
Documentation contributions will earn you lots of hugs and kisses.
A proper readme is forthcoming but in the interim....
These two recipes show how to install and configure logstash instances via the provided LWRPs
See the elkstack community cookbook for a great example of using the LWRPs provided by this cookbook.
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.