#
# Override the system defaults of devd so that configd receives
# both LINK_UP and LINK_DOWN events on wired and wireless devices.
#

notify 101 {
        match "system"          "IFNET";
        match "type"            "LINK_UP";
        media-type              "ethernet";
	action "/usr/local/opnsense/service/configd_ctl.py 'interface linkup start $subsystem'";
};

notify 101 {
        match "system"          "IFNET";
	match "type"            "LINK_DOWN";
	media-type              "ethernet";
	action "/usr/local/opnsense/service/configd_ctl.py 'interface linkup stop $subsystem'";
};

notify 101 {
        match "system"          "IFNET";
        match "type"            "LINK_UP";
	media-type              "802.11";
	action "/usr/local/opnsense/service/configd_ctl.py 'interface linkup start $subsystem'";
};

notify 101 {
        match "system"          "IFNET";
        match "type"            "LINK_DOWN";
	media-type              "802.11";
	action "/usr/local/opnsense/service/configd_ctl.py 'interface linkup stop $subsystem'";
};