def _get_role_arn(name, region=None, key=None, keyid=None, profile=None):
 if name.startswith('arn:aws:iam:'):
  return name
 account_id = __salt__['boto_iam.get_account_id'](region=region, key=key, keyid=keyid, profile=profile)
 return 'arn:aws:iam::{0}:role/{1}'.format(account_id, name)

def _get_role_arn ( name , region = None , key = None , keyid = None , profile = None ) : if name . startswith ( 'arn:aws:iam:' ) : return name account_id = __salt__ [ 'boto_iam.get_account_id' ] ( region = region , key = key , keyid = keyid , profile = profile ) return 'arn:aws:iam::{0}:role/{1}' . format ( account_id , name )
helper function to get an arn if name does not look like an arn .