diff options
author | Bruce Ashfield <bruce.ashfield@gmail.com> | 2019-12-10 02:25:21 -0500 |
---|---|---|
committer | Bruce Ashfield <bruce.ashfield@gmail.com> | 2019-12-10 02:25:21 -0500 |
commit | c31e46fce79f32a6692358105e15d77c652a9c9a (patch) | |
tree | 09f2ee4ebf441f8332531c59aa51d22b0ef61e9e | |
parent | 06ec74ad35999fb87b2be950ead67815d59fbf63 (diff) | |
download | meta-virtualization-c31e46fce79f32a6692358105e15d77c652a9c9a.tar.gz |
conf: add k8s distro feature
Add support for a new distro feature to control kubernetes versions
and related configuration.
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
-rw-r--r-- | README | 1 | ||||
-rw-r--r-- | classes/meta-virt-k8s-cfg.bbclass | 6 | ||||
-rw-r--r-- | conf/distro/include/k8s-versions.inc | 0 | ||||
-rw-r--r-- | conf/layer.conf | 6 |
4 files changed, 11 insertions, 2 deletions
@@ -28,6 +28,7 @@ that may also be enabled: | |||
28 | 28 | ||
29 | - xen: enables xen functionality in various packages (kernel, libvirt, etc) | 29 | - xen: enables xen functionality in various packages (kernel, libvirt, etc) |
30 | - kvm: enables KVM configurations in the kernel and autoloads modules | 30 | - kvm: enables KVM configurations in the kernel and autoloads modules |
31 | - k8s: enables kubernets configurations in the kernel, tools and configuration | ||
31 | - aufs: enables aufs support in docker and linux-yocto | 32 | - aufs: enables aufs support in docker and linux-yocto |
32 | - x11: enable xen and libvirt functionality related to x11 | 33 | - x11: enable xen and libvirt functionality related to x11 |
33 | - selinux: enables functionality in libvirt and lxc | 34 | - selinux: enables functionality in libvirt and lxc |
diff --git a/classes/meta-virt-k8s-cfg.bbclass b/classes/meta-virt-k8s-cfg.bbclass new file mode 100644 index 00000000..1be0a5c8 --- /dev/null +++ b/classes/meta-virt-k8s-cfg.bbclass | |||
@@ -0,0 +1,6 @@ | |||
1 | # We need to load the meta-virt config components, only if "k8s" | ||
2 | # is in the distro features. Since we don't know the distro flags during | ||
3 | # layer.conf load time, we delay using a special bbclass that simply includes | ||
4 | # the K8S_CONFIG_PATH file. | ||
5 | |||
6 | include ${K8S_CONFIG_PATH} | ||
diff --git a/conf/distro/include/k8s-versions.inc b/conf/distro/include/k8s-versions.inc new file mode 100644 index 00000000..e69de29b --- /dev/null +++ b/conf/distro/include/k8s-versions.inc | |||
diff --git a/conf/layer.conf b/conf/layer.conf index 89e5ac2b..d0a7ead0 100644 --- a/conf/layer.conf +++ b/conf/layer.conf | |||
@@ -43,6 +43,8 @@ INHERIT += "sanity-meta-virt" | |||
43 | # We need to load the meta-virt config components, only if "virtualization" | 43 | # We need to load the meta-virt config components, only if "virtualization" |
44 | # is in the distro features. Since we don't know the distro flags during | 44 | # is in the distro features. Since we don't know the distro flags during |
45 | # layer.conf load time, we delay using a special bbclass that simply includes | 45 | # layer.conf load time, we delay using a special bbclass that simply includes |
46 | # the META_VIRT_CONFIG_PATH file. | 46 | # the META_VIRT_CONFIG_PATH file, and likewise for the k8s configs |
47 | META_VIRT_CONFIG_PATH = "${LAYERDIR}/conf/distro/include/meta-virt-default-versions.inc" | 47 | META_VIRT_CONFIG_PATH = "${LAYERDIR}/conf/distro/include/meta-virt-default-versions.inc" |
48 | USER_CLASSES_append = " ${@bb.utils.contains('DISTRO_FEATURES', 'virtualization', 'meta-virt-cfg', '', d)}" \ No newline at end of file | 48 | K8S_CONFIG_PATH = "${LAYERDIR}/conf/distro/include/k8s-versions.inc" |
49 | USER_CLASSES_append = " ${@bb.utils.contains('DISTRO_FEATURES', 'virtualization', 'meta-virt-cfg', '', d)}" | ||
50 | USER_CLASSES_append = " ${@bb.utils.contains('DISTRO_FEATURES', 'k8s', 'meta-virt-k8s-cfg', '', d)}" | ||