08531c1702
This is workaround fix to support baremetal. Following items are remained to support. * Documents * Functional test To test this template, there are some requirements and problem as below. Requirements: * `ephemeral_disk` on ironic baremetal flavor `ephemeral_disk` is used for docker storage instead of cinder volume. * `fixed_subnet` must be setup with dns_nameservers like following. * `neutron subnet-update private-subnet --dns-nameserver 8.8.8.8` * `fixed_subnet` must be IP version 4. if you use devstack, please add following configuration. * `IP_VERSION=4` * Fedora 23 image including kubernetes, etcd, flannel. Problem: Ironic stores `instance_info` about nova instance. `instance_info` contains config_drive data, but this data can be too large to store ironic.nodes table. Magnum uses large config drive data to setup k8s. It means, we can not start ironic instance by Magnum. Workaround fix is changing column type of ironic.nodes.instance_info. Following sql will help you. `alter table ironic.nodes modify instance_info LONGTEXT;` Partial-Implements: blueprint magnum-baremetal-full-support Change-Id: Ica87610b9114bff4277b492de8fe528fe2860108 Closes-Bug: #1454895 Closes-Bug: #1472938 Co-Authored-By: Spyros Trigazis <strigazi@gmail.com> |
||
---|---|---|
.. | ||
Readme.md | ||
elements-deps | ||
package-installs.yaml |
Readme.md
Kubernetes elements
This directory contains [diskimage-builder](https://github.com/openstack/diskimage-builder)
elements to build an image which contains kubernetes required to use kubecluster-fedora-ironic.yaml.
An example fedora based image and uploaded to glance with the following:
git clone https://git.openstack.org/openstack/magnum
git clone https://git.openstack.org/openstack/diskimage-builder.git
git clone https://git.openstack.org/openstack/dib-utils.git
export PATH="${PWD}/dib-utils/bin:$PATH"
export ELEMENTS_PATH=diskimage-builder/elements
export ELEMENTS_PATH=${ELEMENTS_PATH}:magnum/magnum/drivers/k8s_fedora_atomic_v1/image/ironic
export DIB_RELEASE=23
diskimage-builder/bin/disk-image-create baremetal \
fedora selinux-permissive \
kubernetes \
-o fedora-23-kubernetes.qcow2
KERNEL_ID=`glance image-create --name fedora-k8s-kernel \
--visibility public \
--disk-format=aki \
--container-format=aki \
--file=fedora-23-kubernetes.vmlinuz \
| grep id | tr -d '| ' | cut --bytes=3-57`
RAMDISK_ID=`glance image-create --name fedora-k8s-ramdisk \
--visibility public \
--disk-format=ari \
--container-format=ari \
--file=fedora-23-kubernetes.initrd \
| grep id | tr -d '| ' | cut --bytes=3-57`
BASE_ID=`glance image-create --name fedora-k8s \
--os-distro fedora \
--visibility public \
--disk-format=qcow2 \
--container-format=bare \
--property kernel_id=$KERNEL_ID \
--property ramdisk_id=$RAMDISK_ID \
--file=fedora-23-kubernetes.qcow2 \
| grep -v kernel | grep -v ramdisk \
| grep id | tr -d '| ' | cut --bytes=3-57`