cookbook 'Appfirst-Cookbook', '~> 1.0.2'
Appfirst-Cookbook (1) Versions 1.0.2 Follow0
Installs/Configures appfirst collector
cookbook 'Appfirst-Cookbook', '~> 1.0.2', :supermarket
knife supermarket install Appfirst-Cookbook
knife supermarket download Appfirst-Cookbook
Description
Configures an appfirst collector for a given account id. This will also set up a LWRP for creating Nagios checks via Appfirst.
Requirements
Chef 0.10.8 or higher due to using some new syntax.
Recipes
default
This recipe installs and updates the AppFirst client for a given account ID.
Attributes
This recipe will attempt to download the collector if one does not exist locally, or if the current local one is out-of-date.  It will continue 
on failure in case the AppFirst front end is not responding.
Open Appfirst-Cookbook/attributes/default.rb, and edit the variable shown below to reflect your AppFirst account ID.  This can be located in
the appfirst.com WebUI by navigating to the Administration tab, and then clicking 'Setup'.  Click the 'Add More Collectors' link and retrieve the
Account ID from the Collector download URL.  This should look something like  'http://wwws.appfirst.com/packages/initial/xxxx/'
default['appfirst']['appfirst_account_id'] = 'xxxx'
The second noteworthy attribute allows the end user to specify where the
Collector installation package should be stored locally after it is
retrieved from appfirst.com:
default['appfirst']['tmp_file_location'] ='/tmp'
Resources/Providers
Appfirst Check
This LWRP provides an easy way to manage Nagios Checks via Appfirst.
Actions
- 
:createTemplates the specified shell script and updates the NRPE config
- 
:removeremoves the Nagios Check (not implemented)
Attribute Parameters
- 
script_nameThe name of the script being templated
- 
commandThe name of the check, this should be a human readable description, only Alphanumerics and'-"_
- 
warningWarning Level for the Nagios Check (Integer)
- 
criticalCritical Level for the Nagios Check (Integer)
- 
optionsAny additional options to be added to the command in the NRPE config
Examples
appfirst_check "Check_Redis_Memory_Usage" do action :create command "Check_Redis_Memory_Usage" script_name "check_redis_memory_usage.sh" warning 50 critical 75 end
License and Author
Author:: Andrew Gross (andrew@yipit.com)
Licensed under the Buy Me a Beer License
"THE BEER-WARE LICENSE" (Revision 42):
As long as you retain this notice you
can do whatever you want with this stuff. If we meet some day, and you think
this stuff is worth it, you can buy me a beer in return
http://en.wikipedia.org/wiki/Beerware
Dependent cookbooks
This cookbook has no specified dependencies.
Contingent cookbooks
There are no cookbooks that are contingent upon this one.
Collaborator Number Metric
        
            1.0.2 failed this metric
            Failure: Cookbook has 0 collaborators. A cookbook must have at least 2 collaborators to pass this metric.
        
      Contributing File Metric
        
            1.0.2 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
        
      Foodcritic Metric
        
            1.0.2 failed this metric
            FC016: LWRP does not declare a default action: Appfirst-Cookbook/resources/check.rb:1
FC043: Prefer new notification syntax: Appfirst-Cookbook/providers/check.rb:19
FC043: Prefer new notification syntax: Appfirst-Cookbook/providers/check.rb:29
FC064: Ensure issues_url is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC065: Ensure source_url is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC066: Ensure chef_version is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC067: Ensure at least one platform supported in metadata: Appfirst-Cookbook/metadata.rb:1
FC109: Use platform-specific package resources instead of provider property: Appfirst-Cookbook/recipes/default.rb:37
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
        
      No Binaries Metric
        
            1.0.2 passed this metric
        
      Testing File Metric
        
            1.0.2 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
        
            1.0.2 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
        
  
1.0.2 failed this metric
            1.0.2 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
Foodcritic Metric
        
            1.0.2 failed this metric
            FC016: LWRP does not declare a default action: Appfirst-Cookbook/resources/check.rb:1
FC043: Prefer new notification syntax: Appfirst-Cookbook/providers/check.rb:19
FC043: Prefer new notification syntax: Appfirst-Cookbook/providers/check.rb:29
FC064: Ensure issues_url is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC065: Ensure source_url is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC066: Ensure chef_version is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC067: Ensure at least one platform supported in metadata: Appfirst-Cookbook/metadata.rb:1
FC109: Use platform-specific package resources instead of provider property: Appfirst-Cookbook/recipes/default.rb:37
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
        
      No Binaries Metric
        
            1.0.2 passed this metric
        
      Testing File Metric
        
            1.0.2 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
        
            1.0.2 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
        
  
1.0.2 failed this metric
FC043: Prefer new notification syntax: Appfirst-Cookbook/providers/check.rb:19
FC043: Prefer new notification syntax: Appfirst-Cookbook/providers/check.rb:29
FC064: Ensure issues_url is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC065: Ensure source_url is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC066: Ensure chef_version is set in metadata: Appfirst-Cookbook/metadata.rb:1
FC067: Ensure at least one platform supported in metadata: Appfirst-Cookbook/metadata.rb:1
FC109: Use platform-specific package resources instead of provider property: Appfirst-Cookbook/recipes/default.rb:37
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
            1.0.2 passed this metric
        
      Testing File Metric
        
            1.0.2 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
        
            1.0.2 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
        
  
1.0.2 failed this metric
            1.0.2 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