aboutsummaryrefslogtreecommitdiffstats
path: root/classes/cni_networking.bbclass
blob: 9df02b81e6dec2daad94a6f7d8e767f575d10618 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
DEPENDS_append_class-target = " cni"

PACKAGES_prepend = "${PN}-cni "

FILES_${PN}-cni = "${sysconfdir}/cni/net.d/*"

RDEPENDS_${PN}-cni = "cni"

do_install_append() {
    if [ -z "${CNI_NETWORKING_FILES}" ]; then
	bbfatal "cni-networking was inherited, but no networking configuration was provided via CNI_NETWORKING_FILES"
    fi
    install -d "${D}/${sysconfdir}/cni/net.d/"
    for f in ${CNI_NETWORKING_FILES}; do
	conf_name="$(basename $f)"
	install -D -m 0644 "$f" "${D}/${sysconfdir}/cni/net.d/$conf_name"
    done
}