#NEWLINE# def enable_availability_zones( name , availability_zones , region = None , key = None , keyid = None , profile = None ) : #NEWLINE# #INDENT# '\n    Enable availability zones for ELB.\n\n    CLI example:\n\n    .. code-block:: bash\n\n        salt myminion boto_elb.enable_availability_zones myelb \'["us-east-1a"]\'\n    ' #NEWLINE# conn = _get_conn ( region = region , key = key , keyid = keyid , profile = profile ) #NEWLINE# if isinstance ( availability_zones , string_types ) : #NEWLINE# #INDENT# availability_zones = json . loads ( availability_zones ) #NEWLINE# #UNINDENT# try : #NEWLINE# #INDENT# conn . enable_availability_zones ( name , availability_zones ) #NEWLINE# msg = 'Enabled availability_zones on ELB {0}' . format ( name ) #NEWLINE# log . info ( msg ) #NEWLINE# return True #NEWLINE# #UNINDENT# except boto . exception . BotoServerError as error : #NEWLINE# #INDENT# log . debug ( error ) #NEWLINE# msg = 'Failed to enable availability_zones on ELB {0}: {1}' . format ( keyid , error ) #NEWLINE# log . error ( msg ) #NEWLINE# return False