From 242aa9f81b4a54fe4cf4da3c84e802e83c254b2c Mon Sep 17 00:00:00 2001
From: James Martin <jmartin@ansible.com>
Date: Tue, 6 Jan 2015 14:04:03 -0500
Subject: [PATCH] vpc_zone_identifier must be a csv string when an asg is
 updated.

---
 cloud/amazon/ec2_asg.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/cloud/amazon/ec2_asg.py b/cloud/amazon/ec2_asg.py
index 8c9661706b0..6e5d3508cb8 100644
--- a/cloud/amazon/ec2_asg.py
+++ b/cloud/amazon/ec2_asg.py
@@ -326,6 +326,8 @@ def create_autoscaling_group(connection, module):
         for attr in ASG_ATTRIBUTES:
             if module.params.get(attr):
                 module_attr = module.params.get(attr)
+                if attr == 'vpc_zone_identifier':
+                    module_attr = ','.join(module_attr)
                 group_attr = getattr(as_group, attr)
                 # we do this because AWS and the module may return the same list
                 # sorted differently