Update cookbooks and add wordpress cookbook
This commit is contained in:
@@ -1,56 +1,56 @@
|
||||
chef_handler cookbook CHANGELOG
|
||||
===============================
|
||||
# chef_handler cookbook CHANGELOG
|
||||
This file is used to list changes made in each version of the chef_handler cookbook.
|
||||
|
||||
v1.1.9 (2015-05-26)
|
||||
-------------------
|
||||
Bugfixes from 1.1.8 - loading without source is not allowed again.
|
||||
Class unloading is performed more carefully.
|
||||
Tests for resource providers.
|
||||
## v1.3.0 (2016-02-16)
|
||||
- Added state attributes to the custom resource
|
||||
- Added source_url and issues_url to metadata.rb
|
||||
- Replaced attributes for root user and group with the Ohai defined values to simplify the logic of the cookbook
|
||||
- Added lint, unit, and itegration testing in Travis CI
|
||||
- Added Test Kitchen testing of the recipes and the custom resource via a test cookbook
|
||||
- Added Berksfile
|
||||
- Added chefignore and .gitignore files
|
||||
- Added .rubocop.yml config and resolve multiple issues
|
||||
- Updated contributing and testing docs to the latest
|
||||
- Added all testing dependencies to the Gemfile
|
||||
- Added maintainers.md and maintainers.toml files
|
||||
- Expanded the Rakefile for simplified testing
|
||||
|
||||
v1.1.8 (2015-05-14)
|
||||
-------------------
|
||||
Updated Contribution and Readme docs.
|
||||
Fix ChefSpec matchers.
|
||||
Allow handler to load classes when no source is provided.
|
||||
## v1.2.0 (2015-06-25)
|
||||
- Move to support Chef 12+ only. Removes old 'handler class reload' behavior - it isn't necessary because chef-client forks and doesn't share a process between runs.
|
||||
|
||||
v1.1.6 (2014-04-09)
|
||||
-------------------
|
||||
[COOK-4494] - Add ChefSpec matchers
|
||||
## v1.1.9 (2015-05-26)
|
||||
- Bugfixes from 1.1.8 - loading without source is not allowed again. Class unloading is performed more carefully. Tests for resource providers.
|
||||
|
||||
## v1.1.8 (2015-05-14)
|
||||
- Updated Contribution and Readme docs
|
||||
- Fix ChefSpec matchers
|
||||
- Allow handler to load classes when no source is provided.
|
||||
|
||||
v1.1.5 (2014-02-25)
|
||||
-------------------
|
||||
## v1.1.6 (2014-04-09)
|
||||
- [COOK-4494] - Add ChefSpec matchers
|
||||
|
||||
## v1.1.5 (2014-02-25)
|
||||
- [COOK-4117] - use the correct scope when searching the children class name
|
||||
|
||||
|
||||
v1.1.4
|
||||
------
|
||||
## v1.1.4
|
||||
- [COOK-2146] - style updates
|
||||
|
||||
v1.1.2
|
||||
---------
|
||||
## v1.1.2
|
||||
- [COOK-1989] - fix scope for handler local variable to the enable block
|
||||
|
||||
v1.1.0
|
||||
------
|
||||
|
||||
## v1.1.0
|
||||
- [COOK-1645] - properly delete old handlers
|
||||
- [COOK-1322] - support platforms that use 'wheel' as root group'
|
||||
|
||||
v1.0.8
|
||||
------
|
||||
## v1.0.8
|
||||
- [COOK-1177] - doesn't work on windows due to use of unix specific attributes
|
||||
|
||||
v1.0.6
|
||||
------
|
||||
## v1.0.6
|
||||
- [COOK-1069] - typo in chef_handler readme
|
||||
|
||||
v1.0.4
|
||||
------
|
||||
## v1.0.4
|
||||
- [COOK-654] dont try and access a class before it has been loaded
|
||||
- fix bad boolean check (if vs unless)
|
||||
|
||||
v1.0.2
|
||||
------
|
||||
## v1.0.2
|
||||
- [COOK-620] ensure handler code is reloaded during daemonized chef runs
|
||||
|
||||
|
||||
2
cookbooks/chef_handler/CONTRIBUTING.md
Normal file
2
cookbooks/chef_handler/CONTRIBUTING.md
Normal file
@@ -0,0 +1,2 @@
|
||||
Please refer to
|
||||
https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD
|
||||
19
cookbooks/chef_handler/MAINTAINERS.md
Normal file
19
cookbooks/chef_handler/MAINTAINERS.md
Normal file
@@ -0,0 +1,19 @@
|
||||
<!-- This is a generated file. Please do not edit directly -->
|
||||
|
||||
# Maintainers
|
||||
This file lists how this cookbook project is maintained. When making changes to the system, this
|
||||
file tells you who needs to review your patch - you need a simple majority of maintainers
|
||||
for the relevant subsystems to provide a :+1: on your pull request. Additionally, you need
|
||||
to not receive a veto from a Lieutenant or the Project Lead.
|
||||
|
||||
Check out [How Cookbooks are Maintained](https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD)
|
||||
for details on the process and how to become a maintainer or the project lead.
|
||||
|
||||
# Project Maintainer
|
||||
* [Tim Smith](https://github.com/tas50)
|
||||
|
||||
# Maintainers
|
||||
* [Jennifer Davis](https://github.com/sigje)
|
||||
* [Sean OMeara](https://github.com/someara)
|
||||
* [Tim Smith](https://github.com/tas50)
|
||||
* [Thom May](https://github.com/thommay)
|
||||
@@ -1,41 +1,40 @@
|
||||
Description
|
||||
===========
|
||||
# chef_handler Cookbook
|
||||
[](https://travis-ci.org/chef-cookbooks/chef_handler) [](https://supermarket.chef.io/cookbooks/chef_handler)
|
||||
|
||||
Creates a configured handler path for distributing [Chef report and exception handlers](http://docs.chef.io/handlers.html). Also exposes an LWRP for enabling Chef handlers from within recipe code (as opposed to hard coding in the client.rb file). This is useful for cookbook authors who may want to ship a product specific handler (see the `cloudkick` cookbook for an example) with their cookbook.
|
||||
|
||||
Requirements
|
||||
============
|
||||
## Requirements
|
||||
### Platforms
|
||||
- Debian/Ubuntu
|
||||
- RHEL/CentOS/Scientific/Amazon/Oracle
|
||||
- Windows
|
||||
|
||||
* Ruby >= 1.9
|
||||
### Chef
|
||||
- Chef 11+
|
||||
|
||||
Attributes
|
||||
==========
|
||||
### Cookbooks
|
||||
- none
|
||||
|
||||
`node["chef_handler"]["handler_path"]` - location to drop off handlers directory, default is `/var/chef/handlers`.
|
||||
|
||||
Resource/Provider
|
||||
=================
|
||||
|
||||
`chef_handler`
|
||||
--------------
|
||||
## Attributes
|
||||
`node['chef_handler']['handler_path']` - location to drop off handlers directory, default is a folder named 'handlers' in Chef's file cache directory
|
||||
|
||||
## Custom Resources
|
||||
### chef_handler
|
||||
Requires, configures and enables handlers on the node for the current Chef run. Also has the ability to pass arguments to the handlers initializer. This allows initialization data to be pulled from a node's attribute data.
|
||||
|
||||
It is best to declare `chef_handler` resources early on in the compile phase so they are available to fire for any exceptions during the Chef run. If you have a base role you would want any recipes that register Chef handlers to come first in the run_list.
|
||||
|
||||
### Actions
|
||||
#### Actions
|
||||
- `:enable:` Enables the Chef handler for the current Chef run on the current node
|
||||
- `:disable:` Disables the Chef handler for the current Chef run on the current node
|
||||
|
||||
- :enable: Enables the Chef handler for the current Chef run on the current node
|
||||
- :disable: Disables the Chef handler for the current Chef run on the current node
|
||||
#### Attribute Parameters
|
||||
- `class_name:` name attribute. The name of the handler class (can be module name-spaced).
|
||||
- `source:` full path to the handler file. can also be a gem path if the handler ships as part of a Ruby gem.
|
||||
- `arguments:` an array of arguments to pass the handler's class initializer
|
||||
- `supports:` type of Chef Handler to register as, i.e. :report, :exception or both. default is `:report => true, :exception => true`
|
||||
|
||||
### Attribute Parameters
|
||||
|
||||
- class_name: name attribute. The name of the handler class (can be module name-spaced).
|
||||
- source: full path to the handler file. can also be a gem path if the handler ships as part of a Ruby gem.
|
||||
- arguments: an array of arguments to pass the handler's class initializer
|
||||
- supports: type of Chef Handler to register as, i.e. :report, :exception or both. default is `:report => true, :exception => true`
|
||||
|
||||
### Example
|
||||
#### Example
|
||||
|
||||
```ruby
|
||||
# register the Chef::Handler::JsonFile handler
|
||||
@@ -73,30 +72,18 @@ It is best to declare `chef_handler` resources early on in the compile phase so
|
||||
end
|
||||
```
|
||||
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
default
|
||||
-------
|
||||
|
||||
## Usage
|
||||
### default
|
||||
Put the recipe `chef_handler` at the start of the node's run list to make sure that custom handlers are dropped off early on in the Chef run and available for later recipes.
|
||||
|
||||
For information on how to write report and exception handlers for Chef, please see the Chef wiki pages:
|
||||
http://wiki.chef.io/display/chef/Exception+and+Report+Handlers
|
||||
|
||||
json_file
|
||||
---------
|
||||
For information on how to write report and exception handlers for Chef, please see the Chef wiki pages: [https://docs.chef.io/handlers.html](https://docs.chef.io/handlers.html)
|
||||
|
||||
### json_file
|
||||
Leverages the `chef_handler` LWRP to automatically register the `Chef::Handler::JsonFile` handler that ships as part of Chef. This handler serializes the run status data to a JSON file located at `/var/chef/reports`.
|
||||
|
||||
|
||||
Unit Testing
|
||||
==================
|
||||
|
||||
## Unit Testing
|
||||
chef_handler provides built in [chefspec](https://github.com/sethvargo/chefspec) matchers for assisting unit tests. These matchers will only be loaded if chefspec is already loaded. Following is an example of asserting against the jsonfile handler:
|
||||
|
||||
|
||||
```ruby
|
||||
expect(runner).to enable_chef_handler("Chef::Handler::JsonFile").with(
|
||||
source: "chef/handler/json_file",
|
||||
@@ -106,13 +93,12 @@ chef_handler provides built in [chefspec](https://github.com/sethvargo/chefspec)
|
||||
end
|
||||
```
|
||||
|
||||
License and Author
|
||||
==================
|
||||
## License & Authors
|
||||
**Author:** Cookbook Engineering Team ([cookbooks@chef.io](mailto:cookbooks@chef.io))
|
||||
|
||||
Author:: Seth Chisamore (<schisamo@chef.io>)
|
||||
|
||||
Copyright:: 2011, Chef Software, Inc
|
||||
**Copyright:** 2011-2016, Chef Software, Inc.
|
||||
|
||||
```
|
||||
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
|
||||
@@ -124,3 +110,4 @@ 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.
|
||||
```
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#
|
||||
# Author:: Seth Chisamore (<schisamo@chef.io>)
|
||||
# Cookbook Name:: chef_handlers
|
||||
# Attribute:: default
|
||||
# Cookbook Name:: chef_handler
|
||||
# Attributes:: default
|
||||
#
|
||||
# Copyright 2011-2013, Chef Software, Inc
|
||||
# Copyright 2011-2016, Chef Software, Inc
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -18,13 +18,4 @@
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
default["chef_handler"]["root_user"] = "root"
|
||||
|
||||
case platform
|
||||
when "openbsd", "freebsd", "mac_os_x", "mac_os_x_server"
|
||||
default["chef_handler"]["root_group"] = "wheel"
|
||||
else
|
||||
default["chef_handler"]["root_group"] = "root"
|
||||
end
|
||||
|
||||
default["chef_handler"]["handler_path"] = "#{File.expand_path(File.join(Chef::Config[:file_cache_path], '..'))}/handlers"
|
||||
default['chef_handler']['handler_path'] = "#{File.expand_path(File.join(Chef::Config[:file_cache_path], '..'))}/handlers"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#
|
||||
# Author:: Kartik Cating-Subramanian (<ksubramanian@chef.io>)
|
||||
# Copyright:: Copyright (c) 2015 Chef, Inc.
|
||||
# Copyright:: Copyright (c) 2015-2016 Chef Software, Inc.
|
||||
# License:: Apache License, Version 2.0
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
@@ -15,17 +15,15 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
|
||||
module ChefHandler
|
||||
module Helpers
|
||||
|
||||
# Registers a handler in Chef::Config.
|
||||
#
|
||||
# @param handler_type [Symbol] such as :report or :exception.
|
||||
# @param handler [Chef::Handler] handler to register.
|
||||
def register_handler(handler_type, handler)
|
||||
Chef::Log.info("Enabling #{handler.class.name} as a #{handler_type} handler.")
|
||||
Chef::Config.send("#{handler_type.to_s}_handlers") << handler
|
||||
Chef::Config.send("#{handler_type}_handlers") << handler
|
||||
end
|
||||
|
||||
# Removes all handlers that match the given class name in Chef::Config.
|
||||
@@ -34,7 +32,7 @@ module ChefHandler
|
||||
# @param class_full_name [String] such as 'Chef::Handler::ErrorReport'.
|
||||
def unregister_handler(handler_type, class_full_name)
|
||||
Chef::Log.info("Disabling #{class_full_name} as a #{handler_type} handler.")
|
||||
Chef::Config.send("#{handler_type.to_s}_handlers").delete_if { |v| v.class.name == class_full_name }
|
||||
Chef::Config.send("#{handler_type}_handlers").delete_if { |v| v.class.name == class_full_name }
|
||||
end
|
||||
|
||||
# Walks down the namespace heirarchy to return the class object for the given class name.
|
||||
@@ -51,38 +49,7 @@ module ChefHandler
|
||||
# (see COOK-4117).
|
||||
parent = ancestors.inject(Kernel) { |scope, const_name| scope.const_get(const_name, scope === Kernel) }
|
||||
child = parent.const_get(class_name, parent === Kernel)
|
||||
return parent, child
|
||||
end
|
||||
|
||||
# Unloads a given class and reloads it from the file provided.
|
||||
#
|
||||
# @param class_full_name [String] full class name such as 'Chef::Handler::Foo'. If a class
|
||||
# with that name currently exists, its definition is deleted from the enclosing module.
|
||||
# @param file_name [String] full path to the ruby file to be loaded. If path doesn't end with
|
||||
# .rb, that extension is appended.
|
||||
# @return [Class] definition for the freshly loaded class.
|
||||
def reload_class(class_full_name, file_name)
|
||||
begin
|
||||
parent, child = get_class(class_full_name)
|
||||
rescue
|
||||
Chef::Log.debug("#{class_full_name} was not previously loaded.")
|
||||
end
|
||||
|
||||
if child then
|
||||
class_name = class_full_name.split('::').last
|
||||
child = nil
|
||||
parent = Object if parent === Kernel
|
||||
parent.send(:remove_const, class_name)
|
||||
GC.start
|
||||
end
|
||||
|
||||
# Use load instead of require because we need to explicitly avoid any caching that 'require'
|
||||
# performs. If the file has changed, we want to get the changes.
|
||||
file_name << '.rb' unless file_name =~ /.*\.rb$/
|
||||
load file_name
|
||||
|
||||
parent, child = get_class(class_full_name)
|
||||
return child
|
||||
[parent, child]
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# Cookbook Name:: chef_handler
|
||||
# Library:: matchers
|
||||
#
|
||||
# Copyright 2014, Chef Software, Inc.
|
||||
# Copyright 2014-2016, Chef Software, Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -19,12 +19,12 @@
|
||||
#
|
||||
|
||||
if defined?(ChefSpec)
|
||||
chefspec_version = Gem.loaded_specs["chefspec"].version
|
||||
if chefspec_version < Gem::Version.new('4.1.0')
|
||||
define_method = ChefSpec::Runner.method(:define_runner_method)
|
||||
else
|
||||
define_method = ChefSpec.method(:define_matcher)
|
||||
end
|
||||
chefspec_version = Gem.loaded_specs['chefspec'].version
|
||||
define_method = if chefspec_version < Gem::Version.new('4.1.0')
|
||||
ChefSpec::Runner.method(:define_runner_method)
|
||||
else
|
||||
ChefSpec.method(:define_matcher)
|
||||
end
|
||||
|
||||
define_method.call :chef_handler
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -3,7 +3,7 @@
|
||||
# Cookbook Name:: chef_handler
|
||||
# Provider:: default
|
||||
#
|
||||
# Copyright:: 2011-2013, Chef Software, Inc <legal@chef.io>
|
||||
# Copyright:: 2011-2016, Chef Software, Inc <legal@chef.io>
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -25,36 +25,27 @@ def whyrun_supported?
|
||||
end
|
||||
|
||||
# This action needs to find an rb file that presumably contains the indicated class in it and the
|
||||
# load that file. It needs to do this keeping in mind that the same handler class can get enabled
|
||||
# and disabled multiple times and there may be multiple instances of them running around. The
|
||||
# handler code may also have changed between actions. To handle all this, we parse the full class
|
||||
# name and attempt to find its class object, in case it has already been loaded. If such a class
|
||||
# is found, we then attempt to unload that class before we load the file requested. We use "load"
|
||||
# instead of "require" because we want to reload the handler class in case it has changed and
|
||||
# don't want the caching behavior of "require".
|
||||
#
|
||||
# Note that during this process, we also need to keep track of the current handler configuration.
|
||||
# Any of the above steps might fail - in which case we would not want to be in a situation where
|
||||
# we have a registered handler that has been unloaded or mangled.
|
||||
# load that file. It then instantiates that class by name and registers it as a handler.
|
||||
action :enable do
|
||||
class_name = new_resource.class_name
|
||||
new_resource.supports.each do |type, enable|
|
||||
if enable
|
||||
converge_by("disable #{class_name} as a #{type} handler") do
|
||||
unregister_handler(type, class_name)
|
||||
end
|
||||
next unless enable
|
||||
converge_by("disable #{class_name} as a #{type} handler") do
|
||||
unregister_handler(type, class_name)
|
||||
end
|
||||
end
|
||||
|
||||
handler = nil
|
||||
converge_by("load #{class_name} from #{new_resource.source}") do
|
||||
klass = reload_class(class_name, new_resource.source)
|
||||
require new_resource.source
|
||||
_, klass = get_class(class_name)
|
||||
handler = klass.send(:new, *collect_args(new_resource.arguments))
|
||||
end
|
||||
|
||||
new_resource.supports.each do |type, enable|
|
||||
if enable
|
||||
converge_by("enable #{new_resource} as a #{type} handler") do
|
||||
register_handler(type, handler)
|
||||
end
|
||||
next unless enable
|
||||
converge_by("enable #{new_resource} as a #{type} handler") do
|
||||
register_handler(type, handler)
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -83,4 +74,3 @@ def collect_args(resource_args = [])
|
||||
[resource_args]
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#
|
||||
# Author:: Seth Chisamore (<schisamo@chef.io>)
|
||||
# Cookbook Name:: chef_handlers
|
||||
# Cookbook Name:: chef_handler
|
||||
# Recipe:: default
|
||||
#
|
||||
# Copyright 2011, Chef Software, Inc.
|
||||
# Copyright 2011-2016, Chef Software, Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -18,16 +18,15 @@
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
Chef::Log.info("Chef Handlers will be at: #{node['chef_handler']['handler_path']}")
|
||||
Chef::Log.info("Chef Handlers will be located at: #{node['chef_handler']['handler_path']}")
|
||||
|
||||
remote_directory node['chef_handler']['handler_path'] do
|
||||
source 'handlers'
|
||||
# Just inherit permissions on Windows, don't try to set POSIX perms
|
||||
if node["platform"] != "windows"
|
||||
owner node['chef_handler']['root_user']
|
||||
group node['chef_handler']['root_group']
|
||||
mode "0755"
|
||||
unless platform?('windows')
|
||||
owner 'root'
|
||||
mode '0755'
|
||||
recursive true
|
||||
end
|
||||
group node['root_group']
|
||||
action :nothing
|
||||
end.run_action(:create)
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#
|
||||
# Author:: Seth Chisamore (<schisamo@chef.io>)
|
||||
# Cookbook Name:: chef_handlers
|
||||
# Cookbook Name:: chef_handler
|
||||
# Recipe:: json_file
|
||||
#
|
||||
# Copyright 2011, Chef Software, Inc.
|
||||
# Copyright 2011-2016, Chef Software, Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -18,11 +18,11 @@
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
# force resource actions in compile phase so exception handler
|
||||
# force resource actions in compile phase so exception handler
|
||||
# fires for compile phase exceptions
|
||||
|
||||
chef_handler "Chef::Handler::JsonFile" do
|
||||
source "chef/handler/json_file"
|
||||
arguments :path => '/var/chef/reports'
|
||||
chef_handler 'Chef::Handler::JsonFile' do
|
||||
source 'chef/handler/json_file'
|
||||
arguments path: '/var/chef/reports'
|
||||
action :nothing
|
||||
end.run_action(:enable)
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# Cookbook Name:: chef_handler
|
||||
# Resource:: default
|
||||
#
|
||||
# Copyright:: 2011-2013, Chef Software, Inc <legal@chef.io>
|
||||
# Copyright:: 2011-2016, Chef Software, Inc <legal@chef.io>
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -20,15 +20,20 @@
|
||||
|
||||
actions :enable, :disable
|
||||
|
||||
attribute :class_name, :kind_of => String, :name_attribute => true
|
||||
attribute :source, :default => nil, :kind_of => String
|
||||
attribute :arguments, :default => []
|
||||
attribute :supports, :kind_of => Hash, :default => { :report => true, :exception => true }
|
||||
state_attrs :arguments,
|
||||
:class_name,
|
||||
:source,
|
||||
:supports
|
||||
|
||||
# we have to set default for the supports attribute
|
||||
attribute :class_name, kind_of: String, name_attribute: true
|
||||
attribute :source, default: nil, kind_of: String
|
||||
attribute :arguments, default: []
|
||||
attribute :supports, kind_of: Hash, default: { report: true, exception: true }
|
||||
|
||||
# we have to set default for the supports attribute
|
||||
# in initializer since it is a 'reserved' attribute name
|
||||
def initialize(*args)
|
||||
super
|
||||
@action = :enable
|
||||
@supports = { :report => true, :exception => true }
|
||||
@supports = { report: true, exception: true }
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user