2 FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
3 PV = "1.16.2+git${SRCREV_kubernetes}"
4 SRCREV_kubernetes = "c97fe5036ef3df2967d086711e6c0c405941e14b"
6 LICENSE += "(Apache-2.0&MIT)&(Apache-2.0|CC-BY-4.0)"
7 LIC_FILES_CHKSUM_append = " \
8 file://src/import/logo/LICENSE;md5=b431638b9986506145774a9da0d0ad85 \
9 file://src/import/vendor/github.com/morikuni/aec/LICENSE;md5=86852eb2df591157c788f3ba889c8aec \
10 file://src/import/staging/src/k8s.io/sample-controller/LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57 \
11 file://src/import/test/images/kitten/Dockerfile;beginline=1;endline=13;md5=78cb21f802c15df77b75bd56f9417ccf \
12 file://src/import/test/images/nautilus/Dockerfile;beginline=1;endline=13;md5=78cb21f802c15df77b75bd56f9417ccf \
13 file://src/import/staging/src/k8s.io/kubectl/LICENSE;md5=e3fc50a88d0a364313df4b21ef20c29e \
14 file://src/import/vendor/github.com/grpc-ecosystem/go-grpc-middleware/LICENSE;md5=7ab5c73bb7e4679b16dd7c11b3559acf \
17 SRC_URI = "git://github.com/kubernetes/kubernetes.git;branch=release-1.16;name=kubernetes \
18 file://0001-hack-lib-golang.sh-use-CC-from-environment.patch \
19 file://0001-cross-don-t-build-tests-by-default.patch \
20 file://kubernetes-accounting.conf \
22 file://kubelet-cgroup-setup.sh \
26 INSANE_SKIP_${PN} += "textrel"
27 INSANE_SKIP_${PN}-misc += "textrel"
28 INSANE_SKIP_kubelet += "textrel"
32 install -d ${D}${bindir}
33 install -d ${D}${systemd_system_unitdir}/
36 install -m 755 -D ${S}/src/import/_output/local/bin/${TARGET_GOOS}/${TARGET_GOARCH}/* ${D}/${bindir}
39 install -d -m 0755 ${D}/${sysconfdir}/systemd/system/kubelet.service.d
40 install -m 0644 ${WORKDIR}/kubeadm.conf ${D}/${sysconfdir}/systemd/system/kubelet.service.d
42 # kubelete-cgroup-setup.sh
43 install -m 0700 ${WORKDIR}/kubelet-cgroup-setup.sh ${D}/${bindir}
45 # install the bash completion
46 install -d -m 0755 ${D}${datadir}/bash-completion/completions/
47 ${D}${bindir}/kubectl completion bash > ${D}${datadir}/bash-completion/completions/kubectl
49 # install config files
50 install -d -m 0755 ${D}${sysconfdir}/${BPN}
51 install -m 644 -t ${D}${sysconfdir}/${BPN} ${WORKDIR}/contrib/init/systemd/environ/*
53 # install service files
54 install -d -m 0755 ${D}${systemd_system_unitdir}
55 install -m 0644 -t ${D}${systemd_system_unitdir} ${WORKDIR}/contrib/init/systemd/*.service
57 # install the place the kubelet defaults to put volumes
58 install -d ${D}${localstatedir}/lib/kubelet
60 # install systemd tmpfiles
61 install -d -m 0755 ${D}${sysconfdir}/tmpfiles.d
62 install -p -m 0644 -t ${D}${sysconfdir}/tmpfiles.d ${WORKDIR}/contrib/init/systemd/tmpfiles.d/kubernetes.conf
64 # enable CPU and Memory accounting
65 install -d -m 0755 ${D}/${sysconfdir}/systemd/system.conf.d
66 install -m 0644 ${WORKDIR}/kubernetes-accounting.conf ${D}/${sysconfdir}//systemd/system.conf.d/
69 SYSTEMD_PACKAGES += "${PN} kube-proxy"
70 SYSTEMD_SERVICE_kube-proxy = "kube-proxy.service"
71 SYSTEMD_SERVICE_${PN} = "\
72 kube-scheduler.service \
73 kube-apiserver.service \
74 kube-controller-manager.service \
76 SYSTEMD_AUTO_ENABLE_${PN} = "disable"
77 SYSTEMD_AUTO_ENABLE_kubelet = "disable"
78 SYSTEMD_AUTO_ENABLE_kube-proxy = "disable"
81 ${bindir}/kube-scheduler \
82 ${bindir}/kube-apiserver \
83 ${bindir}/kube-controller-manager \
85 ${bindir}/kubelet-cgroup-setup.sh \
89 ${datadir}/bash-completion/completions/kubectl \
93 ${bindir}/conversion-gen \
94 ${bindir}/openapi-gen \
95 ${bindir}/apiextensions-apiserver \
96 ${bindir}/defaulter-gen \
98 ${bindir}/deepcopy-gen \
99 ${bindir}/go-bindata \