* README.md: Add informations for the xymon::server class.

This commit is contained in:
gardouille 2015-02-24 14:09:19 +01:00
parent b5967d6b37
commit e70f6e4d78
2 changed files with 80 additions and 4 deletions

View File

@ -1,6 +1,22 @@
---------------------------------------
###
#### Summary
This is a release introduce the Xymon server management.
##### Features
* xymon::server::install will install Xymon server and it's dependancies.
* xymon::server::config will provide some configuration files.
* xymon::server::service will manage the service.
* xymon::server::apache will provide a virtual host for Apache2.
##### Changes
* README.md: Add informations for the xymon::server class.
---------------------------------------
### 0.1.0 - 2015/02/17
Inital release.

View File

@ -8,6 +8,7 @@
* [What xymon affects](#what-xymon-affects)
* [Beginning with Xymon](#beginning-with-xymon)
4. [Usage](#usage)
* [Server](#server)
* [Client](#client)
5. [Reference](#reference)
* [Public classes](#public-classes)
@ -20,7 +21,7 @@
## Overview
The Xymon module provide a simple way to manage the last version of Xymon (client only right now) based on the packages provide by the Xymon project (deb files but could be rpm if passed as argument).
The Xymon module provide a simple way to manage the last version of Xymon based on the packages provide by the Xymon project (packages could be rpm if passed as argument).
## Module Description
@ -32,12 +33,21 @@ The xymon module automates installing Xymon on systems.
* Package/service/configuration files for Xymon.
* Recommends and suggests packages for Xymon-plugins (aka hobbit-plugins).
* Default Apache2 configuration (puppetlabs-apache).
* Virtual host for Xymon server.
### Beginning with xymon
To begin using xymon module with default parameters, declare the client class (server not yet available):
To begin using xymon module with default parameters, declare the server class:
```
include xymon::client
include xymon::server
```
And on others nodes, the client:
```
class { 'xymon::client':
list_server => [ '192.168.0.10' ]
}
```
If you manage the sudoers with Puppet or a module (saz-sudo for example), you should add permissions for the Xymon user to be able to run some additional plugins:
@ -52,6 +62,36 @@ sudo::conf { 'xymon':
## Usage
### Server
#### Default behaviour
By default, the server class will manage both server and client (ensure install but disable the service) for Xymon, the virtual host for Apache2 and somes configurations files for Xymon server:
```
class { 'xymon::server': }
```
If you choose a different version, it will also be applied to the `xymon::client` class.
#### Disable client management
If you prefer to manage the Xymon client separately:
```
class { 'xymon::server':
manage_client => false,
}
```
#### Disable Apache configuration and virtual host:
The virtual host for Apache2 look like the one provide by the project (http://sourceforge.net/p/xymon/code/HEAD/tree/branches/4.3.17/xymond/etcfiles/xymon-apache-secure.DIST), if you prefer a vhost and Apache2 managed by yourself:
```
class { 'xymon::server':
manage_apache_conf => false,
manage_apache_vhost => false,
}
```
### Client
#### Define the server
@ -69,7 +109,6 @@ node 'second.toto' {
list_server => [ '127.0.0.1', '192.168.0.10' ],
}
}
```
**Note**: `list_server` must be an array even if you have only one Xymon server.
@ -88,10 +127,16 @@ class {
### Public classes
* `xymon`: Main class, do nothing right now.
* `xymon::server`: Install and manage Xymon server.
* `xymon::client`: Install and manage Xymon client.
### Private classes
* `xymon::server::preconfig`: Ensure `xymon::client` class is defined and build dl_url and pkg_name variables with the parameters.
* `xymon::server::install`: Install the server packages.
* `xymon::server::config`: Provide some contribution files.
* `xymon::server::service`: Manage the Xymon server service.
* `xymon::server::apache`: Ensure the `::apache` class is defined (from puppetlabs-apache) and provide a virtual host.
* `xymon::client::preconfig`: Build the dl_url and pkg_name, with the parameters, to download the Xymon client package.
* `xymon::client::install`: Install the packages.
* `xymon::client::config`: Manage the configuration files.
@ -99,6 +144,21 @@ class {
### Parameters
#### xymon::server
* `dep_pkg_name`: The list of depends packages to install Xymon server. Could be an array. Defaults to [ 'debconf', 'libc-ares2', 'libc6', 'libldap-2.4-2', 'libpng12-0', 'librrd4', 'libssl1.0.0', 'perl' ].
* `download_dir`: The directory to store Xymon packages. Defaults to '/opt/xymon/packages'.
* `download_url`: The URL to download Xymon server package. Should not be complete: **http://www.download/path/to/4.3.17/** will work but http://www.download/path/to/4.3.17/package.deb **will not work**. You must use the `package_name` variable. Defaults to 'undef'.
* `new_version`: The version of Xymon to download. Defaults to '4.3.17'.
* `package_name`: The Xymon server's package name to download and install. Defaults to undef.
* `pkg_ensure`: What to set the Xymon server package to. Can be 'present' or 'absent'. Defaults to 'present'.
* `pkg_provider`: The provider used to install Xymon server package. Defaults to 'dpkg'.
* `service_enabled`: If set to 'true', Puppet will ensure the Xymon server's service is running. Can be 'true' or 'false'. Defaults to 'true'.
* `service_managed`: If set to 'true', Puppet will manage the Xymon server's service. Can be 'true' or 'false'. Defaults to 'true'.
* `service_name`: Xymon server's service name. Defaults to 'xymon'.
* `manage_client`: If set to 'true', the `xymon::server` class will also manage a default installation of the client with `xymon::client` class. Can be 'true' or 'false'. Defaults to 'true'.
* `manage_apache_conf`: If set to 'true', Puppet will ensure the `::apache` is defined otherwise it will defined a default one with 'mpm module'. Can be 'true' or 'false'. Defaults to 'true'.
* `manage_apache_vhost`: If set to 'true', Puppet will provide a virtual host for Apache. Can be 'true' or 'false'. Defaults to 'true'.
#### xymon::client
* `download_dir`: The directory to store Xymon packages. Defaults to '/opt/xymon/packages'.