def get_docker_tag_name(image):
    cmd = ("docker inspect --format '{{.ContainerConfig.Labels.Tag}}' " + image)
    proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True, text=True)
    (out, _) = proc.communicate()
    if (proc.returncode != 0):
        return 'unknown'
    tag = out.rstrip()
    if (tag == '<no value>'):
        return 'unknown'
    return tag
def get_docker_tag_name(image):
    cmd = ("docker inspect --format '{{.ContainerConfig.Labels.Tag}}' " + image)
    proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True, text=True)
    (out, _) = proc.communicate()
    if (proc.returncode != 0):
        return 'unknown'
    tag = out.rstrip()
    if (tag == '<no value>'):
        return 'unknown'
    return tag