cookbook 'prometheus', '= 0.5.1'
prometheus (6) Versions 0.5.1 Follow8
Installs/Configures Prometheus
cookbook 'prometheus', '= 0.5.1', :supermarket
knife supermarket install prometheus
knife supermarket download prometheus
prometheus Cookbook
This cookbook installs the Prometheus monitoring system and time-series database.
Requirements
- Chef 11 or higher
- Ruby 1.9.3 or higher
Platform
Tested on
- Ubuntu 14.04
- Ubuntu 12.04
- Debian 7.7
- Centos 6.6
- Centos 7.0
Attributes
In order to keep the README managable and in sync with the attributes, this
cookbook documents attributes inline. The usage instructions and default
values for attributes can be found in the individual attribute files.
Recipes
default
The default
recipe installs creates all the default Prometheus directories,
config files and and users. Default also calls the configured install_method
recipe and finally calls the prometheus service
recipe.
source
The source
recipe builds Prometheus from a Github source tag.
binary
The binary
recipe retrieves and installs a pre-compiled Prometheus build from
a user-defined location.
service
The service
recipe configures Prometheus to run under a process supervisor.
Default supervisors are chosen based on distribution. Currently supported
supervisors are init, runit, systemd and bluepill. (Upstart coming soon)
Resource/Provider
prometheus_job
This resource adds a job definition to the Prometheus config file. Here is an
example of using this resource to define the default Prometheus job:
prometheus_job ‘prometheus’ do scrape_interval ‘15s’ target “http://localhost#{node[‘prometheus’][‘flags’][‘web.listen-address’]}#{node[‘prometheus’][‘flags’][‘web.telemetry-path’]}” end
Note: This cookbook uses the accumulator pattern so you can define multiple
prometheus_job’s and they will all be added to the Prometheus config.
Externally managing prometheus.conf
If you prefer to manage your prometheus.conf
file externally using your own
inventory or service discovery mechanism you can set
default[‘prometheus’][‘allow_external_config’]
to true
.
Dependencies
The following cookbooks are dependencies:
Usage
prometheus::default
Include prometheus
in your node's run_list
:
{ "run_list": [ "recipe[prometheus::default]" ] }
Development
Please see the [Contributing](CONTRIBUTING.md) and [Issue Reporting](ISSUES.md) Guidelines.
License & Authors
- Author: Ray Rodriguez rayrod2030@gmail.com
- Author: kristian järvenpää kristian.jarvenpaa@gmail.com
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.
Dependent cookbooks
apt >= 0.0.0 |
yum >= 0.0.0 |
build-essential >= 0.0.0 |
runit ~> 1.5 |
bluepill ~> 2.3 |
accumulator >= 0.0.0 |
ark >= 0.0.0 |
Contingent cookbooks
There are no cookbooks that are contingent upon this one.
Change Log
All notable changes to this project will be documented in this file.
Unreleased
0.5.1 - 2015-03-25
Changed
- Updated documentation.
0.5.0 - 2015-03-25
Added
- Added systemd init for redhat platform family version 7 or greater.
- Default init style per platform.
- Install Prometheus via pre-compiled binary.
- Added the prometheus_job resource for defining Prometheus scraping jobs.
- Attribute flag to externally manage prometheus.conf file.
Changed
- Removed flags that were deprecated in the prometheus 0.12.0 release.
Contributors for this release:
- Eric Richardson - External jobs config and prometheus job resource.
Thank You!
0.4.0 - 2015-03-12
Fixed
- Fix init template path bug on chef 11.x.
0.3.0 - 2015-03-11
Fixed
- Fixed cookbook badge in README
0.2.0 - 2015-03-11
Fixed
- License defined in metadata.
0.1.0 - 2015-03-11
Changed
- Initial release of prometheus cookbook
Collaborator Number Metric
0.5.1 passed this metric
Contributing File Metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Cookstyle Metric
0.5.1 failed this metric
Chef/Correctness/ScopedFileExist: Scope file exist to access the correct File class by using ::File.exist? not File.exist?. (https://docs.chef.io/workstation/cookstyle/chef_correctness_scopedfileexist): prometheus/recipes/source.rb: 43
Chef/Deprecations/ResourceWithoutUnifiedTrue: Set `unified_mode true` in Chef Infra Client 15.3+ custom resources to ensure they work correctly in Chef Infra Client 18 (April 2022) when Unified Mode becomes the default. (https://docs.chef.io/workstation/cookstyle/chef_deprecations_resourcewithoutunifiedtrue): prometheus/resources/job.rb: 1
Chef/Modernize/UseBuildEssentialResource: Use the build_essential resource instead of the legacy build-essential recipe. This resource ships in the build-essential cookbook v5.0+ and is built into Chef Infra Client 14+ (https://docs.chef.io/workstation/cookstyle/chef_modernize_usebuildessentialresource): prometheus/recipes/source.rb: 20
Chef/RedundantCode/NamePropertyIsRequired: Resource properties marked as name properties should not also be required properties (https://docs.chef.io/workstation/cookstyle/chef_redundantcode_namepropertyisrequired): prometheus/resources/job.rb: 4
Run with Cookstyle Version 7.32.1 with cops Chef/Deprecations,Chef/Correctness,Chef/Sharing,Chef/RedundantCode,Chef/Modernize,Chef/Security,InSpec/Deprecations
No Binaries Metric
0.5.1 passed this metric
Testing File Metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.5.1 passed this metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Cookstyle Metric
0.5.1 failed this metric
Chef/Correctness/ScopedFileExist: Scope file exist to access the correct File class by using ::File.exist? not File.exist?. (https://docs.chef.io/workstation/cookstyle/chef_correctness_scopedfileexist): prometheus/recipes/source.rb: 43
Chef/Deprecations/ResourceWithoutUnifiedTrue: Set `unified_mode true` in Chef Infra Client 15.3+ custom resources to ensure they work correctly in Chef Infra Client 18 (April 2022) when Unified Mode becomes the default. (https://docs.chef.io/workstation/cookstyle/chef_deprecations_resourcewithoutunifiedtrue): prometheus/resources/job.rb: 1
Chef/Modernize/UseBuildEssentialResource: Use the build_essential resource instead of the legacy build-essential recipe. This resource ships in the build-essential cookbook v5.0+ and is built into Chef Infra Client 14+ (https://docs.chef.io/workstation/cookstyle/chef_modernize_usebuildessentialresource): prometheus/recipes/source.rb: 20
Chef/RedundantCode/NamePropertyIsRequired: Resource properties marked as name properties should not also be required properties (https://docs.chef.io/workstation/cookstyle/chef_redundantcode_namepropertyisrequired): prometheus/resources/job.rb: 4
Run with Cookstyle Version 7.32.1 with cops Chef/Deprecations,Chef/Correctness,Chef/Sharing,Chef/RedundantCode,Chef/Modernize,Chef/Security,InSpec/Deprecations
No Binaries Metric
0.5.1 passed this metric
Testing File Metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.5.1 failed this metric
Chef/Deprecations/ResourceWithoutUnifiedTrue: Set `unified_mode true` in Chef Infra Client 15.3+ custom resources to ensure they work correctly in Chef Infra Client 18 (April 2022) when Unified Mode becomes the default. (https://docs.chef.io/workstation/cookstyle/chef_deprecations_resourcewithoutunifiedtrue): prometheus/resources/job.rb: 1
Chef/Modernize/UseBuildEssentialResource: Use the build_essential resource instead of the legacy build-essential recipe. This resource ships in the build-essential cookbook v5.0+ and is built into Chef Infra Client 14+ (https://docs.chef.io/workstation/cookstyle/chef_modernize_usebuildessentialresource): prometheus/recipes/source.rb: 20
Chef/RedundantCode/NamePropertyIsRequired: Resource properties marked as name properties should not also be required properties (https://docs.chef.io/workstation/cookstyle/chef_redundantcode_namepropertyisrequired): prometheus/resources/job.rb: 4
Run with Cookstyle Version 7.32.1 with cops Chef/Deprecations,Chef/Correctness,Chef/Sharing,Chef/RedundantCode,Chef/Modernize,Chef/Security,InSpec/Deprecations
0.5.1 passed this metric
Testing File Metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.5.1 failed this metric
0.5.1 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number