From e27338181cba2a3c07d9f47a650cde9a22c1b2f9 Mon Sep 17 00:00:00 2001 From: Jeff Geerling Date: Thu, 20 Feb 2020 18:18:00 -0600 Subject: [PATCH] Fixes issue with python 3 on Ubuntu 18.04 tests. --- README.md | 14 +++++++++----- defaults/main.yml | 8 ++------ molecule/default/converge.yml | 5 +++++ 3 files changed, 16 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 078fdcb..e158e7c 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,12 @@ If you would like to view munin's graphs and output via HTTP, you will need an H Available variables are listed below, along with default values (see `defaults/main.yml`): + munin_packages: + - python-passlib + - munin + +Packages installed for Munin. If you are running Python 3, you should override this variable and set the first item to `python3-passlib`. + munin_dbdir: /var/lib/munin munin_htmldir: /var/www/html/munin munin_logdir: /var/log/munin @@ -52,15 +58,13 @@ A listing of hosts to which munin will connect and monitor. Each item in the lis See documentation for [Munin Node Definitions](http://munin.readthedocs.org/en/latest/reference/munin.conf.html#node-definitions) for more details as to what values to use here. -You can enable mail alerts by adding : - munin_alerts: - - { - name: "JohnDoe", + - name: "JohnDoe", email: "johndoe@example.com", subject: "Munin-notification for ${var:group} :: ${var:host}", level: "warning critical" - } + +You can configure email alerts using the `munin_alerts` variable. ## Dependencies diff --git a/defaults/main.yml b/defaults/main.yml index 338e5a4..3f29b23 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -31,16 +31,12 @@ munin_admin_password: munin # Note that `name` can be hostname, or group + hostname, for example: # [example.com;foo.example.com] munin_hosts: - - { - name: "localhost", + - name: "localhost", address: "127.0.0.1", extra: ["use_node_name yes"] - } munin_alerts: [] -# - { -# name: "JohnDoe", +# - name: "JohnDoe", # email: "johndoe@example.com", # subject: "Munin-notification for ${var:group} :: ${var:host}", # level: "warning critical" -# } diff --git a/molecule/default/converge.yml b/molecule/default/converge.yml index d1b1a66..92cbd33 100644 --- a/molecule/default/converge.yml +++ b/molecule/default/converge.yml @@ -3,6 +3,11 @@ hosts: all become: true + vars: + munin_packages: + - python3-passlib + - munin + pre_tasks: - name: Update apt cache. apt: update_cache=true cache_valid_time=600