Browse Source

Add RHEL nodes (#85)

CentOS was doing the jobs but it was missing to link for Red Hat
distribution and the choise to don't use epel repository.

Tested and works on RHEL 7.3

Signed-off-by: Cyril Lopez <cylopez@redhat.com>
Cyril Lopez 8 years ago
parent
commit
47b85ba76f
7 changed files with 10 additions and 2 deletions
  1. 1 0
      CHANGELOG.md
  2. 3 0
      defaults/main.yml
  3. 2 0
      docs/role_variables.md
  4. 1 1
      tasks/CentOS/rabbit.yml
  5. 1 1
      tasks/CentOS/redis.yml
  6. 1 0
      tasks/RedHat
  7. 1 0
      vars/RedHat.yml

+ 1 - 0
CHANGELOG.md

@@ -7,6 +7,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/).
 ### Changed
 - Rely on the existing sensu repositories to install Uchiwa
 - Use the latest version of the FreeBSD package
+- Add Red Hat node
 
 ### Fixed
 - Make sure any local directories that are assumed exist actually do

+ 3 - 0
defaults/main.yml

@@ -98,6 +98,9 @@ uchiwa_port: 3000
 uchiwa_refresh: 5
 uchiwa_sensu_api_port: "{{ sensu_api_port }}"
 
+# CentOS repository for redis and rabbitmq
+centos_repository: epel
+
 # Internal settings
 __bash_path: /bin/bash
 __root_group: root

+ 2 - 0
docs/role_variables.md

@@ -114,6 +114,8 @@ _Note: The above options are intended to provide users with flexibility. This al
 |--------------------|---------------|------------------------------|
 | `sensu_user_name`    | root        | The name of the Sensu service user |
 | `sensu_group_name`   | root        | The name of the Sensu service user's primary group |
+| `centos_repository`   | epel        | The name of repository use for redis or rabbitmq packages. If it set as empty string, it's using the repository already enable on the node |
+
 
 ## SmartOS
 ### [RabbitMQ Server Properties](https://sensuapp.org/docs/latest/reference/rabbitmq)

+ 1 - 1
tasks/CentOS/rabbit.yml

@@ -10,4 +10,4 @@
         - erlang
         - rabbitmq-server
       state: present
-      enablerepo: epel
+      enablerepo: "{{ centos_repository }}"

+ 1 - 1
tasks/CentOS/redis.yml

@@ -8,7 +8,7 @@
     yum:
       name: "{{ redis_pkg_name }}"
       state: "{{ redis_pkg_state }}"
-      enablerepo: epel
+      enablerepo: "{{ centos_repository }}"
 
   - name: Ensure redis binds to accessible IP
     lineinfile:

+ 1 - 0
tasks/RedHat

@@ -0,0 +1 @@
+CentOS

+ 1 - 0
vars/RedHat.yml

@@ -0,0 +1 @@
+CentOS.yml