OP#436 add user access
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
- [Synopsis](#synopsis)
|
||||
- [WARNING](#warning)
|
||||
- [Features](#features)
|
||||
- [configuring user access](#configuring-user-access)
|
||||
- [Repo Documentation](#repo-documentation)
|
||||
- [Dependencies](#dependencies)
|
||||
- [Deployment](#deployment)
|
||||
@@ -33,6 +34,9 @@ Nagios is a powerful open source software solution for monitoring your IT enviro
|
||||
- if FQDN equals the specified `ng_nagios_server`, nagios server with all required specs is installed, else only nagios client packages and the target specs
|
||||
- if `ng_include_nrpe`is set to `true`, the confdroid_nrpe module is automatically applied on clients ([confdroid_nrpe](https://sourcecode.confdroid.com/confdroid/confdroid_nrpe) must be in the catalogue then )
|
||||
|
||||
### configuring user access
|
||||
ToDo
|
||||
|
||||
## Repo Documentation
|
||||
|
||||
See the full Puppet documentation including parameters in `docs/index.html`
|
||||
|
||||
@@ -28,6 +28,10 @@
|
||||
# to use HTTPS. Default is false. We recommend using a reverse proxy
|
||||
# with SSL termination in front of the Nagios web interface, so this is
|
||||
# disabled by default.
|
||||
# @param [String] ng_main_user The username for the Nagios web interface.
|
||||
# Default is 'nagios'.
|
||||
# @param [String] ng_main_password The encrypted password for the Nagios web
|
||||
# interface. Default is 'nagios'.
|
||||
###############################################################################
|
||||
class confdroid_nagios::params (
|
||||
|
||||
@@ -37,6 +41,8 @@ class confdroid_nagios::params (
|
||||
Array $ng_reqpackages_client = ['net-snmp-utils','nagios-plugins','nagios-plugins-all','nagios-plugins-nrpe','nagios-common'],
|
||||
String $ng_pkg_ensure = 'present',
|
||||
Boolean $ng_include_nrpe = true,
|
||||
String $ng_main_user = 'nagios',
|
||||
String $ng_main_password = 'nagios',
|
||||
|
||||
# httpd
|
||||
Boolean $ng_use_https = false,
|
||||
|
||||
@@ -21,5 +21,12 @@ class confdroid_nagios::server::access_rules (
|
||||
seluser => system_u,
|
||||
notify => Service[$ng_nagios_service],
|
||||
}
|
||||
}
|
||||
|
||||
# manage file header
|
||||
concat::fragment { 'fle_header':
|
||||
target => $ng_htpasswd_file,
|
||||
content => template($ng_htpasswd_head),
|
||||
order => '000',
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
2
templates/nagios/htpasswd_head.erb
Normal file
2
templates/nagios/htpasswd_head.erb
Normal file
@@ -0,0 +1,2 @@
|
||||
<%= @ng_main_user %>:<%= @ng_main_password %>
|
||||
# custom lines below
|
||||
Reference in New Issue
Block a user