diff options
author | Yibo Cai <yibo.cai@arm.com> | 2017-12-26 17:06:24 +0800 |
---|---|---|
committer | Yibo Cai <yibo.cai@arm.com> | 2018-02-14 09:59:50 +0800 |
commit | c8ccf3efae4a91d13ce5c87b53d312e55c02727c (patch) | |
tree | 23d43125c58359d0f43aae0223a3b389cc837376 | |
parent | 5dd3af7fd00971a96d91397f9754e6455abb660d (diff) |
doc: add arm deployment guide
Change-Id: Ib66003003ea4697e9634201802e9169bc53a8ade
Signed-off-by: Yibo Cai <yibo.cai@arm.com>
-rw-r--r-- | docs/release/installation/k8s-deploy-arm.rst | 106 |
1 files changed, 106 insertions, 0 deletions
diff --git a/docs/release/installation/k8s-deploy-arm.rst b/docs/release/installation/k8s-deploy-arm.rst new file mode 100644 index 00000000..b5b54c20 --- /dev/null +++ b/docs/release/installation/k8s-deploy-arm.rst @@ -0,0 +1,106 @@ +.. This work is licensed under a Creative Commons Attribution 4.0 International Licence. +.. http://creativecommons.org/licenses/by/4.0 +.. (c) by Yibo Cai (Arm) + +Validated platform +================== + +================ ========= ================ ======== + Jump server Node +--------------------------- -------------------------- +distro libvirt distro k8s +================ ========= ================ ======== +ubuntu 16.04.3 1.3.1 centos7 1708 1.7.5 +================ ========= ================ ======== + +Prepare jump server +=================== +This document assumes you are using a baremetal Arm server as Compass4NFV jump server. It's possible to deploy jump server inside a virtual machine, this case is not covered here. + +#. Install Ubuntu 16.04.3 aarch64 on jump server. + +#. Install required packages. + + .. code-block:: bash + + $ sudo apt install docker.io libvirt-bin virt-manager qemu qemu-efi + +#. Disable DHCP of default libvirt network. + + Libvirt creates a default network at intallation, which enables DHCP and occupies port 67. It conflicts with compass-cobbler container. + + .. code-block:: bash + + $ sudo virsh net-edit default + + .. code-block:: xml + + <!-- remove below lines and save/quit -> + <dhcp> + <range start='192.168.122.2' end='192.168.122.254'/> + </dhcp> + + .. code-block:: bash + + $ sudo virsh net-destroy default + $ sudo virsh net-start default + +#. Make sure ports 67, 69, 80, 443 are free. + + Compass-cobber requires ports 67, 69 to provide DHCP and TFTP services. Compass-deck provides HTTP and HTTPS through ports 80, 443. All these ports should be free before deployment. + +#. Tear down apparmor service. + + .. code-block:: bash + + $ sudo service apparmor teardown + +#. Enable password-less sudo for current user (optional). + + +Build Arm tarball +================= + +Clone Compass4NFV code. Run below command to build deployment tarball for Arm. + +.. code-block:: bash + + $ COMPASS_ISO_REPO='http://people.linaro.org/~yibo.cai/compass' ./build.sh + +It downloads and archives Ubuntu/CentOS installation ISO and Compass core docker images for later deployment. + + +Deploy K8s in VM +================ +This section introduces the steps to deploy K8s cluster in virtual machines running on jump server. Two VM nodes will be created, one master and one minion, with flannel networking. + +Clear old Compass core +---------------------- + +Compass core consists of five containers which are responsible for deploying K8s clusters. + +- *compass-deck*: provides API service and web UI +- *compass-tasks*: deploy K8s to nodes +- *compass-cobbler*: deploy OS to nodes +- *compass-db*: mysql service +- *compass-mq*: rabbitmq service + +Run below command to remove running Compass containers for a clean deployment. + +.. code-block:: bash + + $ docker rm -f `docker ps | grep compass | cut -f1 -d' '` + +Deploy OS and K8s +----------------- +To deploy OS and K8s on two virtual nodes, run: + +.. code-block:: bash + + $ ADAPTER_OS_PATTERN='(?i)CentOS-7.*arm.*' \ + OS_VERSION=centos7 \ + KUBERNETES_VERSION=v1.7.5 \ + DHA=${PWD}/deploy/conf/vm_environment/k8-nosdn-nofeature-noha.yml \ + NETWORK=${PWD}/deploy/conf/vm_environment/network.yml \ + VIRT_NUMBER=2 VIRT_CPUS=4 VIRT_MEM=8192 VIRT_DISK=50G \ + ./deploy.sh |