/kubernetes-cluster

Deploy addons to a barebones kubernetes cluster

Primary LanguageShellMIT LicenseMIT

Kubernetes Cluster addons

Deploy addons to a barebones kubernetes cluster.

Addons include:

Installing addons

Script install.sh will install all addons in the correct order.

Installing individual addons

Individual addons can be installed by sourcing the corresponding addon.sh and running the different steps in order. For example, for prometheus addon:

cd prometheus
source addon.sh
addon_prep
addon_install

The addon can be removed with the corresponding addon_remove function.

Note that there are dependencies between the addons (see install.sh) and installing/removing addons out of order might break the cluster. For example, the calico addon enables prometheus metrics, but ServiceMonitors cannot be added until the prometheus addon is installed.

Secrets

All secrets are generated dynamically. Those need for access are printed out.

Dependencies

  • kubectl to manage the cluster.
  • docker to prepare some addons without installing tools locally.
  • jq to parse and manipulate json output.
  • helm to install Helm charts.
  • curl to install some third party tools and access APIs.

Vagrant Setup

These scripts recognize Kubernets clusters running in Vagrant when nodes have domain private.test. Special provision is made in this case to further automate addon installation(), i.e. OpenEBS Cstor blockdevices) and reduce resources (i.e. 1GB prometheus volume).

Vagrant cluster are recognized by the is_vagrant() bash function, which can be modified to match your domain name.

License

MIT

Author

Luis Gracia while at Rockefeller University:

  • lgracia [at] rockefeller.edu
  • GitHub at luisico