def is_bond_member(yaml, ifname):
    """Returns True if this interface is a member of a BondEthernet."""
    if not "bondethernets" in yaml:
        return False

    for _bond, iface in yaml["bondethernets"].items():
        if not "interfaces" in iface:
            continue
        if ifname in iface["interfaces"]:
            return True
    return False