Git Product home page Git Product logo

k8s-sona-ansible's Introduction

k8s-sona-ansible

travis_build

An automated installation script used for installing Kubernetes, Docker, OpenvSwitch, ONOS, SONA-CNI and Helm.

Requirements

  • Operating System
    • CentOS 7.7 (kernel: 3.10.0-1062)
    • Ubuntu 16.04, 18.04 (LTS)
  • Network:
    • Primary (internal): management, tunneling
    • Secondary (external): NodeIP, routing
  • Nodes:
    • 1 master node
    • 0 ~ n worker nodes

Components to be installed

  • Mandatory
    • Kubernetes with Dashboard
    • ONOS with SONA-CNI
    • OpenvSwitch
    • Docker
  • Optional
    • Helm
    • Healthcheck

Installation

  1. Install ansible and git at master node.

CentOS:

# yum install ansible git -y

Ubuntu:

16.04:

If you are running Ubuntu 16.04, the pre-installed ansible does not support multi-tasks, and this in turn causes runtime failure. To resolve this issue, the users need to following this guide to upgrade ansible to higher version.

18.04 or higher:

If you are running Ubuntu 18.04 or higher version, no need to manually upgrade ansible.

# apt-get install ansible git -y
  1. Generate RSA key at master node. Make sure do not create any passphrase.
# ssh-keygen -t rsa
  1. Configure the hostname of each node. Run following command at each node to configure the hostname.
# hostnamectl set-hostname $node-name

(Optional) Add configured hostname and IP address pair to /etc/hosts at master node. Followings are the example configuration.

master  192.168.56.101
worker  192.168.56.201
  1. Copy RSA public key from master node and distribute to all nodes (master + worker).
# ssh-copy-id root@$node-name
  1. Clone k8s-sona-ansible script at master node.
# git clone https://github.com/sonaproject/k8s-sona-ansible.git
  1. Add hosts.ini by referring to the example config from inventory/default/hosts.ini.example.
[master]
192.168.56.101

[worker]
192.168.56.201

[cluster:children]
master
worker
  1. Add all.yml by referring to the example config from inventory/default/group_vars/all.yml.example. Make sure you have configured the correct ext_intf, and ext_gw_ip. Typically we use secondary network as the external network. It is also possible to install optional packages (e.g., helm, healthcheck) by toggling the flag to true at all.yml.

  2. Run ansible script at master node.

# ansible-playbook inventory/default/site.yml
  1. Enjoy!

Site Reset

In case you would like to reset the entire environments, run following ansible script at master node. Note that site reset does not uninstall Kubernetes, OpenvSwitch and Docker.

# ansible-playbook inventory/default/reset-site.yml

Important Pointers

  • For latest updates, visit project page.
  • For manually installation, visit installation page
  • Report bugs or new requirement(s) on the bug page.
  • Any contribution is appreciated.
  • Start contributing and enjoy ;)

License

Apache 2.0

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.