import re


def _filter_name(stack_name,regex_str):
    """
    filter a list of string by regex
    :param stack_name:
    :param regex_str:
    :return: if stack name is in regex
    """
    return bool(re.search(regex_str, stack_name))