From 2daf5f3edb64cbafd05d929eb8d3a60ea72ce98b Mon Sep 17 00:00:00 2001 From: Tim Rupp Date: Fri, 1 Jun 2018 14:38:23 -0700 Subject: [PATCH] Correct states in bigip_pool_member (#41035) Fixes: #40631 The module was not correctly handling a certain state where the node could be down, but the monitor was enabled on the node. This patch fixes it. --- lib/ansible/modules/network/f5/bigip_pool_member.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/ansible/modules/network/f5/bigip_pool_member.py b/lib/ansible/modules/network/f5/bigip_pool_member.py index 15bf7b862a..7dd868fea6 100644 --- a/lib/ansible/modules/network/f5/bigip_pool_member.py +++ b/lib/ansible/modules/network/f5/bigip_pool_member.py @@ -465,6 +465,8 @@ class ApiParameters(Parameters): def state(self): if self._values['state'] in ['user-up', 'unchecked', 'fqdn-up-no-addr'] and self._values['session'] in ['user-enabled']: return 'present' + elif self._values['state'] == 'down' and self._values['session'] == 'monitor-enabled': + return 'present' elif self._values['state'] in ['user-down'] and self._values['session'] in ['user-disabled']: return 'forced_offline' else: