Version information
This version is compatible with:
- Puppet Enterprise 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x, 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x, 2018.1.x
- Puppet >=5.5.10 <8.0.0
- , , , , , , ,
Start using this module
Add this module to your Puppetfile:
mod 'bodgit-nut', '2.0.1'
Learn more about managing modules with a PuppetfileDocumentation
nut
Table of Contents
- Description
- Setup - The basics of getting started with nut
- Usage - Configuration options and additional functionality
- Reference - An under-the-hood peek at what the module is doing and how
- Limitations - OS compatibility, etc.
- Development - Guide for contributing to the module
Description
This module ensures that the Network UPS Tools (NUT) are installed and configured.
RHEL/CentOS, Ubuntu, Debian and OpenBSD are supported using Puppet 5 or later.
Setup
What nut affects
This module will potentially configure your host to respond to power failures.
Setup Requirements
On RHEL/CentOS platforms you will need to have access to the EPEL repository by using stahnma/epel or by other means.
Beginning with nut
In the very simplest case, you can just include the following:
include ::nut
Usage
The above example is not terribly useful as it does not include any UPS devices, so it should be extended to something like the following:
include ::nut
::nut::ups { 'sua1000i':
driver => 'usbhid-ups',
port => 'auto',
}
::nut::user { 'local':
password => 'password',
upsmon => 'master',
}
::nut::user { 'remote':
password => 'password',
upsmon => 'slave',
}
::nut::client::ups { 'sua1000i@localhost':
user => 'local',
password => 'password',
}
If the host does not have any UPS device directly attached, but is powered by one which is controlled by another host such as the one above, use the following:
include ::nut:client
::nut::client::ups { 'sua1000i@remotehost':
user => 'remote',
password => 'password',
}
Reference
The reference documentation is generated with puppet-strings and the latest version of the documentation is hosted at https://bodgit.github.io/puppet-nut/ and available also in the REFERENCE.md.
Limitations
This module has been built on and tested against Puppet 5 and higher.
The module has been tested on:
- RedHat Enterprise Linux 6/7
- Ubuntu 14.04/16.04
- Debian 8
- OpenBSD 6.0
Development
The module relies on PDK and has both rspec-puppet and beaker-rspec tests. Run them with:
$ bundle exec rake spec
$ PUPPET_INSTALL_TYPE=agent PUPPET_INSTALL_VERSION=x.y.z bundle exec rake beaker:<nodeset>
Please log issues or pull requests at github.
Reference
Table of Contents
Classes
nut
: Installs Network UPS Tools (NUT).nut::cgi
: Installs the Network UPS Tools (NUT) CGI scripts.nut::cgi::config
nut::cgi::install
nut::client
: Installs the Network UPS Tools (NUT) client.nut::client::config
nut::common
nut::common::config
nut::common::install
nut::common::service
nut::config
nut::install
nut::params
nut::service
Defined types
nut::cgi::ups
: Add a UPS to visualise with the CGI scripts.nut::client::ups
: Add a local or remote UPS to monitor.nut::client::upssched
: Define actions forupssched
.nut::ups
: Adds and configures a UPS.nut::user
: Configure a user for UPS access.
Data types
Classes
nut
Installs Network UPS Tools (NUT).
- See also
- puppet_classes::nut::client
- ::nut::client
- puppet_defined_types::nut::ups
- ::nut::ups
- puppet_defined_types::nut::user
- ::nut::user
- puppet_defined_types::nut::client::ups
- ::nut::client::ups
- puppet_defined_types::nut::client::upssched
- ::nut::client::upssched
- puppet_classes::nut::client
Examples
Declaring the class
include ::nut
Listening on local subnet
class { '::nut':
listen => [
{
'address' => $::ipaddress_eth0,
},
{
'address' => $::ipaddress6_eth0,
},
],
}
Parameters
The following parameters are available in the nut
class.
certfile
Data type: Optional[Stdlib::Absolutepath]
Path to OpenSSL TLS certificate and key.
Default value: undef
certident
Data type: Optional[Tuple[String, String]]
Tuple of certificate name and NSS database password.
Default value: undef
certpath
Data type: Optional[Stdlib::Absolutepath]
Path to NSS certificate database.
Default value: undef
certrequest
Data type: Optional[Enum['no', 'request', 'require']]
Client certificate authentication options for NSS.
Default value: undef
client_certident
Data type: Optional[Tuple[String, String]]
Default value: undef
client_certpath
Data type: Optional[Stdlib::Absolutepath]
Default value: undef
client_certverify
Data type: Optional[Boolean]
Default value: undef
client_cmdscript
Data type: Optional[Stdlib::Absolutepath]
Default value: undef
client_deadtime
Data type: Optional[Integer[0]]
Default value: undef
client_finaldelay
Data type: Optional[Integer[0]]
Default value: undef
client_forcessl
Data type: Optional[Boolean]
Default value: undef
client_hostsync
Data type: Optional[Integer[0]]
Default value: undef
client_manage_package
Data type: Boolean
If the client is installed with the same
package then set this to false
.
Default value: $::nut::params::client_manage_package
client_manage_service
Data type: Boolean
If the client is started as part of the same
service as the server then set this to false
.
Default value: $::nut::params::client_manage_service
client_minsupplies
Data type: Integer[1]
Default value: 1
client_nocommwarntime
Data type: Optional[Integer[0]]
Default value: undef
client_use_upssched
Data type: Boolean
Default value: false
client_notifycmd
Data type: Optional[Stdlib::Absolutepath]
Default value: $client_use_upssched
client_notifyflag
Data type: Optional[Hash[Nut::Event, Tuple[Boolean, 3, 3]]]
Default value: undef
client_notifymsg
Data type: Optional[Hash[Nut::Event, String]]
Default value: undef
client_package_name
Data type: String
Default value: $::nut::params::client_package_name
client_pollfreq
Data type: Optional[Integer[0]]
Default value: undef
client_pollfreqalert
Data type: Optional[Integer[0]]
Default value: undef
client_rbwarntime
Data type: Optional[Integer[0]]
Default value: undef
client_service_name
Data type: String
Default value: $::nut::params::client_service_name
client_shutdowncmd
Data type: String
Default value: $::nut::params::shutdown_command
conf_dir
Data type: Stdlib::Absolutepath
Top-level configuration directory, usually /etc/nut
or
/etc/ups
.
Default value: $::nut::params::conf_dir
driver_packages
Data type: Hash[String, String]
Hash of driver types to the package that provides it.
Default value: $::nut::params::driver_packages
group
Data type: String
The unprivileged group used to drop root privileges.
Default value: $::nut::params::group
listen
Data type: Optional[Array[Nut::Listen, 1]]
An array of hashes of interface addresses to listen on, optionally with a port.
Default value: undef
maxage
Data type: Optional[Integer[1]]
Timeout for UPS drivers.
Default value: undef
maxconn
Data type: Optional[Integer[1]]
Maximum number of connections.
Default value: undef
package_name
Data type: String
The name of the package.
Default value: $::nut::params::server_package_name
service_name
Data type: String
Name of the service.
Default value: $::nut::params::server_service_name
statepath
Data type: Stdlib::Absolutepath
Top-level state directory, usually /var/run/nut
or
/var/db/nut
.
Default value: $::nut::params::state_dir
user
Data type: String
The unprivileged user used to drop root privileges.
Default value: $::nut::params::user
nut::cgi
Installs the Network UPS Tools (NUT) CGI scripts.
- See also
- puppet_classes::nut
- ::nut
- puppet_defined_types::nut::cgi::ups
- ::nut::cgi::ups
- puppet_classes::nut
Examples
Declaring the class
include ::nut::cgi
Managing the virtual host configuration elsewhere
class { '::nut::cgi':
manage_vhost => false,
}
Parameters
The following parameters are available in the nut::cgi
class.
apache_resources
Data type: Hash
Hash of Apache resources to create that configures the virtual host serving the CGI scripts.
Default value: $::nut::params::apache_resources
conf_dir
Data type: Stdlib::Absolutepath
Top-level configuration directory, usually
/var/www/conf/nut
or /etc/ups
.
Default value: $::nut::params::cgi_conf_dir
group
Data type: String
The unprivileged group used to drop root privileges.
Default value: $::nut::params::group
http_server
Data type: Enum['apache', 'httpd']
Which HTTP server to configure a virtual host for.
Default value: $::nut::params::http_server
manage_vhost
Data type: Boolean
Whether to create a virtual host for the CGI scripts or not.
Default value: $::nut::params::manage_vhost
package_name
Data type: String
The name of the package.
Default value: $::nut::params::cgi_package_name
user
Data type: String
The unprivileged user used to drop root privileges.
Default value: $::nut::params::user
nut::cgi::config
The nut::cgi::config class.
nut::cgi::install
The nut::cgi::install class.
nut::client
Installs the Network UPS Tools (NUT) client.
- See also
- puppet_defined_types::nut::client::ups
- ::nut::client::ups
- puppet_defined_types::nut::client::upssched
- ::nut::client::upssched
- puppet_defined_types::nut::client::ups
Examples
Declaring the class
include ::nut::client
Using upssched
for notifications
class { '::nut::client':
use_upssched => true,
}
Parameters
The following parameters are available in the nut::client
class.
certident
Data type: Optional[Tuple[String, String]]
Tuple of certificate name and NSS database password.
Default value: undef
certpath
Data type: Optional[Stdlib::Absolutepath]
Path to NSS certificate database.
Default value: undef
certverify
Data type: Optional[Boolean]
Verify any TLS connections.
Default value: undef
cmdscript
Data type: Optional[Stdlib::Absolutepath]
The script invoked by upssched
when a timer expires.
Default value: undef
conf_dir
Data type: Stdlib::Absolutepath
Top-level configuration directory, usually /etc/nut
or
/etc/ups
.
Default value: $::nut::params::conf_dir
deadtime
Data type: Optional[Integer[0]]
How long a UPS can go without reporting anything before being declared dead.
Default value: undef
finaldelay
Data type: Optional[Integer[0]]
How long to wait after warning users before shutting the host down.
Default value: undef
forcessl
Data type: Optional[Boolean]
Always use TLS connections.
Default value: undef
group
Data type: String
The unprivileged group used to drop root privileges.
Default value: $::nut::params::group
hostsync
Data type: Optional[Integer[0]]
Wait this long for slave hosts to disconnect in a shutdown situation.
Default value: undef
minsupplies
Data type: Integer[1]
The number of power supplies receiving power for the host to remain powered on.
Default value: 1
nocommwarntime
Data type: Optional[Integer[0]]
How oftern to warn when no configured UPS is reachable.
Default value: undef
notifycmd
Data type: Optional[Stdlib::Absolutepath]
The command to invoke for UPS events.
Default value: $use_upssched
notifyflag
Data type: Optional[Hash[Nut::Event, Tuple[Boolean, 3, 3]]]
Hash of UPS event to tuple of three booleans representing
using Syslog, wall(1)
and $notifycmd
for notifications.
Default value: undef
notifymsg
Data type: Optional[Hash[Nut::Event, String]]
Hash of UPS event to string for overriding the message for that event.
Default value: undef
package_name
Data type: String
The name of the package.
Default value: $::nut::params::client_package_name
pollfreq
Data type: Optional[Integer[0]]
How often to poll a UPS.
Default value: undef
pollfreqalert
Data type: Optional[Integer[0]]
How often to poll a UPS running on battery.
Default value: undef
rbwarntime
Data type: Optional[Integer[0]]
How often to warn a UPS needs a replacement battery.
Default value: undef
service_name
Data type: String
The name of the service.
Default value: $::nut::params::client_service_name
shutdowncmd
Data type: String
The command used to power the host off.
Default value: $::nut::params::shutdown_command
state_dir
Data type: Stdlib::Absolutepath
Top-level state directory, usually /var/run/nut
or
/var/db/nut
.
Default value: $::nut::params::state_dir
use_upssched
Data type: Boolean
Whether to use upssched
for notifications or not.
Default value: false
user
Data type: String
The unprivileged user used to drop root privileges.
Default value: $::nut::params::user
nut::client::config
The nut::client::config class.
nut::common
The nut::common class.
Parameters
The following parameters are available in the nut::common
class.
conf_dir
Data type: Stdlib::Absolutepath
group
Data type: String
minsupplies
Data type: Integer[1]
package_name
Data type: String
service_name
Data type: String
shutdowncmd
Data type: String
state_dir
Data type: Stdlib::Absolutepath
use_upssched
Data type: Boolean
user
Data type: String
certident
Data type: Optional[Tuple[String, String]]
Default value: undef
certpath
Data type: Optional[Stdlib::Absolutepath]
Default value: undef
certverify
Data type: Optional[Boolean]
Default value: undef
cmdscript
Data type: Optional[Stdlib::Absolutepath]
Default value: undef
deadtime
Data type: Optional[Integer[0]]
Default value: undef
finaldelay
Data type: Optional[Integer[0]]
Default value: undef
forcessl
Data type: Optional[Boolean]
Default value: undef
hostsync
Data type: Optional[Integer[0]]
Default value: undef
manage_package
Data type: Boolean
Default value: true
manage_service
Data type: Boolean
Default value: true
nocommwarntime
Data type: Optional[Integer[0]]
Default value: undef
notifycmd
Data type: Optional[Stdlib::Absolutepath]
Default value: undef
notifyflag
Data type: Optional[Hash[Nut::Event, Tuple[Boolean, 3, 3]]]
Default value: undef
notifymsg
Data type: Optional[Hash[Nut::Event, String]]
Default value: undef
pollfreq
Data type: Optional[Integer[0]]
Default value: undef
pollfreqalert
Data type: Optional[Integer[0]]
Default value: undef
rbwarntime
Data type: Optional[Integer[0]]
Default value: undef
nut::common::config
The nut::common::config class.
nut::common::install
The nut::common::install class.
nut::common::service
The nut::common::service class.
nut::config
The nut::config class.
nut::install
The nut::install class.
nut::params
The nut::params class.
nut::service
The nut::service class.
Defined types
nut::cgi::ups
Add a UPS to visualise with the CGI scripts.
- See also
- puppet_classes::nut::cgi
- ::nut::cgi
- puppet_classes::nut::cgi
Examples
Visualise a UPS
include ::nut::cgi
::nut::cgi::ups { 'sua1000i@remotehost':
description => 'A remote UPS',
}
Parameters
The following parameters are available in the nut::cgi::ups
defined type.
description
Data type: String
Description of the UPS.
ups
Data type: Nut::Device
The UPS to visualise.
Default value: $title
nut::client::ups
Add a local or remote UPS to monitor.
- See also
- puppet_classes::nut::client
- ::nut::client
- puppet_defined_types::nut::client::upssched
- ::nut::client::upssched
- puppet_classes::nut::client
Examples
Monitoring a local UPS
include ::nut
::nut::ups { 'sua1000i':
driver => 'usbhid-ups',
port => 'auto',
}
::nut::user { 'test':
password => 'password',
upsmon => 'master',
}
::nut::client::ups { 'sua1000i@localhost':
user => 'test',
password => 'password',
type => 'master',
}
Monitoring a remote UPS
include ::nut::client
::nut::client::ups { 'sua1000i@remotehost':
user => 'test',
password => 'password',
type => 'slave',
}
Parameters
The following parameters are available in the nut::client::ups
defined type.
user
Data type: String
Username to use to connect to upsd
.
password
Data type: String
Password to use to connect to upsd
.
certhost
Data type: Optional[Tuple[String, Boolean, Boolean]]
If using NSS and client certificate authentication specify a tuple of certificate name, whether to verify and whether to force TLS with the remote host.
Default value: undef
powervalue
Data type: Integer[0]
How many power supplies does this UPS feed.
Default value: 1
type
Data type: Enum['master', 'slave']
Is the UPS being monitored attached to the local system or not.
Default value: $title
ups
Data type: Nut::Device
The UPS to monitor.
Default value: $title
nut::client::upssched
Define actions for upssched
.
- See also
- puppet_classes::nut::client
- ::nut::client
- puppet_defined_types::nut::client::ups
- ::nut::client::ups
- puppet_classes::nut::client
Examples
Configure an action when local UPS has disconnected
class { '::nut::client':
use_upssched => true,
}
::nut::client::upssched { 'local ups has disconnected':
args => [
'upsgone',
10,
],
command => 'start-timer',
notifytype => 'commbad',
ups => 'test@localhost',
}
Parameters
The following parameters are available in the nut::client::upssched
defined type.
args
Data type: Array[Variant[String, Integer], 1]
Additional arguments to pass to the command.
command
Data type: Enum['start-timer', 'cancel-timer', 'execute']
The command to run.
notifytype
Data type: Nut::Event
The event notification to apply the action to.
ups
Data type: Variant[Nut::Device, Enum['*']]
The UPS to apply the action to, or "*" to apply to all.
nut::ups
Adds and configures a UPS.
- See also
- puppet_classes::nut
- ::nut
- puppet_defined_types::nut::user
- ::nut::user
- puppet_classes::nut
Examples
Adding a USB-connected Smart-UPS 1000i
include ::nut
::nut::ups { 'sua1000i':
driver => 'usbhid-ups',
port => 'auto',
}
Parameters
The following parameters are available in the nut::ups
defined type.
driver
Data type: String
The driver to use for this UPS.
port
Data type: Variant[Integer[0, 65535], String]
The port or device name where the UPS is attached.
extra
Data type: Hash[String, Any]
Any additional driver-specific options can be passed here.
Default value: {}
ups
Data type: String
The name of the UPS.
Default value: $title
nut::user
Configure a user for UPS access.
- See also
- puppet_classes::nut
- ::nut
- puppet_defined_types::nut::ups
- ::nut::ups
- puppet_classes::nut
Examples
Declaring a user
include ::nut
::nut::user { 'test':
password => 'password',
}
Declaring a upsmon user
include ::nut
::nut::user { 'monmaster':
password => 'secret',
upsmon => 'master',
}
Parameters
The following parameters are available in the nut::user
defined type.
password
Data type: String
The password for the user.
actions
Data type: Optional[Array[String, 1]]
List of actions to permit the user to do.
Default value: undef
instcmds
Data type: Optional[Array[String, 1]]
List of instant commands the user can initiate.
Default value: undef
upsmon
Data type: Optional[Enum['master', 'slave']]
Set the user to be used by upsmon.
Default value: undef
user
Data type: String
The name of the user.
Default value: $title
Data types
Nut::Device
The Nut::Device data type.
Alias of Pattern[/\A[^@]+@[^:]+(:\d+)?\Z/]
Nut::Event
The Nut::Event data type.
Alias of Enum['online', 'onbatt', 'lowbatt', 'fsd', 'commok', 'commbad', 'shutdown', 'replbatt', 'nocomm']
Nut::Listen
The Nut::Listen data type.
Alias of Struct[{'address' => Stdlib::IP::Address::NoSubnet, Optional['port'] => Integer[0, 65535]}]
Change log
All notable changes to this project will be documented in this file. The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
v2.0.1 (2021-03-06)
Added
v2.0.0 (2020-11-12)
Changed
Added
- Bump dependencies #10 (bodgit)
- Convert to PDK #8 (bodgit)
- Replace deprecated thrnio/ip module by puppetlabs/stdlib #7 (simondeziel)
v1.0.3 (2020-10-17)
Added
Fixed
- nut::client::config: preserve OS/package settings of state_dir #4 (simondeziel)
v1.0.2 (2019-07-18)
Fixed
- nut::common: add missing config variables #3 (simondeziel)
v1.0.1 (2017-11-06)
v1.0.0 (2017-01-19)
* This Changelog was automatically generated by github_changelog_generator
Dependencies
- puppetlabs/stdlib (>=4.25.0 <7.0.0)
- puppetlabs/concat (>=2.1.0 <8.0.0)
- puppetlabs/apache (>=1.0.0 <7.0.0)
Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright 2013 Puppet Labs 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.