Coder Social home page Coder Social logo

academy_microk8s's Introduction

academy_microk8s

Installation Script for microk8s

In short, microk8s is designed to be a fast and lightweight upstream Kubernetes install isolated from your host but not via a virtual machine. This isolation is achieved by packaging all the upstream binaries for Kubernetes, Docker.io, iptables, and CNI in a single snap package. The snap package is an application container?—?you can imagine this as a lighter weight version of a Docker container. It uses a lot of the same underlying technologies for isolation just without all the overhead of network isolation.

Installing SNAP on Centos


https://computingforgeeks.com/install-snapd-snap-applications-centos-7/

Installing Kubernetes (microk8s)


https://microk8s.io/
microk8s installs a barebones upstream Kubernetes. This means just the api-server, controller-manager, scheduler, kubelet, cni, kube-proxy are installed and run. Additional services like kube-dns and dashboard can be run using the microk8s.enable command.
> microk8s.enable dns dashboard

User Interface

URL http://127.0.0.1:80/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy/#!/overview?namespace=default

Information of Kubernetes Installation


> microk8s.kubectl cluster-info

Path to microk8s.* Binaries


/var/lib/snapd/snap/bin/

Start nginx Containers


> microk8s.kubectl get all --all-namespaces > microk8s.kubectl run nginx --image nginx --replicas 3
> microk8s.kubectl expose deployment nginx --port 80 --target-port 80 --type ClusterIP --selector=run=nginx --name nginx
> microk8s.kubectl get all
> microk8s.kubectl get svc
> curl http://localhost

Remove nginx


> microk8s.kubectl delete deployment/nginx
> microk8s.kubectl get all
> microk8s.kubectl delete svc/nginx

Troubleshoot microk8s


> microk8s.inspect

Restart microk8s


> sudo snap disable microk8s > sudo snap enable microk8s

Remove microk8s


> microk8s.disable dashboard dns
> sudo snap remove microk8s

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.