From 963ad4250ad765340aec5c35299d906b228f5324 Mon Sep 17 00:00:00 2001 From: Nasenbaer Date: Thu, 5 Nov 2015 11:42:56 +0100 Subject: [PATCH] Allow setting of custom dimensions in asg alarm specification --- salt/states/boto_asg.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/salt/states/boto_asg.py b/salt/states/boto_asg.py index be5da63176..047860beda 100644 --- a/salt/states/boto_asg.py +++ b/salt/states/boto_asg.py @@ -610,7 +610,8 @@ def _alarms_present(name, alarms, alarms_from_pillar, region, key, keyid, profil info['name'] = name + ' ' + info['name'] info['attributes']['description'] = name + ' ' + info['attributes']['description'] # add dimension attribute - info['attributes']['dimensions'] = {'AutoScalingGroupName': [name]} + if 'dimensions' not in info['attributes']: + info['attributes']['dimensions'] = {'AutoScalingGroupName': [name]} # set alarm kwargs = { 'name': info['name'],