MicroK8s documentation - home

MicroK8s is a low-ops, minimal production Kubernetes.

MicroK8s is an open-source system for automating deployment, scaling, and management of containerised applications. It provides the functionality of core Kubernetes components, in a small footprint, scalable from a single node to a high-availability production cluster.

By reducing the resource commitments required in order to run Kubernetes, MicroK8s makes it possible to take Kubernetes into new environments, for example:

  • turning Kubernetes into lightweight development tool
  • making Kubernetes available for use in minimal environments such as GitHub CI
  • adapting Kubernetes for small-appliance IoT applications

Developers use MicroK8s as an inexpensive proving ground for new ideas. In production, ISVs benefit from lower overheads and resource demands and shorter development cycles, enabling them to ship appliances faster than ever.

The MicroK8s ecosystem includes dozens of useful Addons - extensions that provide additional functionality and features. See list of Addons, How to manage Addons.


In this documentation

Tutorials
Get started - a hands-on introduction to MicroK8s for new users
How-to guides
Step-by-step guides covering key operations and common tasks
Explanation
Concepts - discussion and clarification of key topics
Reference
Technical information - specifications, commands, architecture

Project and community

MicroK8s is an open source project that welcomes community contributions, suggestions, fixes and constructive feedback.

Navigation

Navigation
Level Path Navlink
0 / Home
1 tutorials Tutorials
2 /getting-started Getting started
1 how-to How to Guides
2 install-alternatives Installing
3 install-windows ā€¦on Windows 10/11
3 install-macos ā€¦on macOS
3 install-raspberry-pi ā€¦on a Raspberry Pi
3 nvidia-dgx ā€¦on NVIDIA DGX
3 install-lxd ā€¦with LXD
3 install-multipass ā€¦using Multipass
3 install-wsl2 ā€¦ with WSL2
3 install-proxy ā€¦behind a proxy
3 install-offline ā€¦offline or airgapped
3 install-strict ā€¦with strict confinement
3 install-alternatives Additional install notes
3 setting-snap-channel set channels/versions
2 addons Addons
3 how-to-manage-addons How to manage Addons
3 howto-addons Create, edit and use community addons
2 config Configuration
3 configuring-services Configure services
3 configure-host-interfaces Configure host interfaces
3 configure-cni Configure CNI
3 add-launch-config Add launch configurations
3 how-to-dual-stack Configure Dual-stack (IPv4I/Pv6)
3 change-cidr Change the pod CIDR
3 external-lma Add an LMA stack
3 external-etcd Use an external etcd cluster
3 multi-user Set up MicroK8s for more users
3 oidc-dex Set up OIDC to work with Dex
2 cluster Clusters
3 clustering Create a multi-node cluster
3 upgrade-cluster Upgrade a cluster
3 high-availability Get High Availability
3 restore-quorum Recover from a lost quorum on dqlite
2 Cluster API Cluster API
3 capi-provision Provisioning with Cluster API
3 capi-manage Managing CAPI clusters
3 capi-upgrade Upgrading a CAPI cluster
2 images Images and registries
3 registry-images Use local images
3 registry-public Use a public registry
3 registry-built-in Use the built-in registry
3 registry-private Use a private registry
3 sideload Side-load images
2 upgrading Upgrading
3 manage-upgrades-with-a-snap-store-proxy Manage upgrades with a Snap Store Proxy
3 upgrade-cluster Upgrade a cluster
2 security-how-to Security
3 how-to-cis-harden CIS hardening
3 security-trivy Run security scans with Trivy
2 how-to-storage Storage
3 how-to-ceph Use MicroCeph/Ceph storage
3 how-to-nfs Use NFS for Persistent Volumes
2 eks-d Installing EKS-D with MicroK8s
2 ingress Use the ingress addon
2 ports#headingā€“auth Use authentication and authorization
2 add-a-windows-worker-node-to-microk8s Add Windows workers
2 velero Backup workloads with Velero
2 dockerhub-limits Manage DockerHub rate limits
2 build-microk8s-snap Build the MicroK8s snap
2 troubleshooting Troubleshooting
1 explanation Explanation
2 high-availability High Availability
2 snap-refreshes Snap package refreshes
2 strict-confinement Strict confinement
2 explain-launch-config Launch configuration
2 clusterapi Cluster API (CAPI)
2 explain-dual-stack Dual-stack (IPv4.IPv6)
2 compliance Security Compliance
3 cis-compliance CIS Hardening
1 reference Reference
2 release-notes Release notes
2 community Welcome to the community!
2 command-reference Command reference
2 services-and-ports Services and ports used
2 working-with-kubectl Working with kubectl
2 addons Addons
2 ref-launch-config Launch configuration
2 ref-build-env Build variables
2 ref-ubuntu-pro Ubuntu Pro for MicroK8s
2 get-in-touch Get in touch
2 troubleshooting#headingā€“report-bug Reporting a bug
2 docs/docs Contributing to docs
addons-test addon test page
addons#headingā€“list Available addons
addon-ambassador ambassador
addon-cloudnative-pg cloudnative-pg
addon-dashboard dashboard
addon-dns dns
addon-easyhaproxy EasyHAProxy
addon-falco Falco
addon-fluentd fluentd
addon-gpu gpu
addon-gopaddle-lite gopaddle-lite
addon-host-access host-access
addon-inaccel inaccel
addon-ingress ingress
addon-kata kata
addon-keda keda
addon-kubeflow kubeflow
addon-kube-ovn KubeOVN
addon-kubearmor KubeArmor
addon-kwasm KWasm
addon-linkerd linkerd
addon-metallb metallb
addon-microrocks microrocks
addon-minio minio
addon-multus multus
addon-ngrok ngrok
addon-ondat ondat
addon-openfaas openfaas
addon-openebs openebs
addon-portainer portainer
addon-traefik traefik
addon-mayastor-1 mayastor
addon-mayastor mayastor
addon-nfs nfs
addon-ngrok ngrok
addon-osm osm-edge
addon-parking addon-parking
addon-hostpath-storage addon-hostpath
addon-cert-manager addon-cert-manager
addon-rook-ceph addon-rook-ceph
addon-sosivio addon-sosivio
addon-shifu addon-shifu
aws-user-guide AWS Appliance Deployment Guide
how-to How to Guides
capi-management CAPI upgrades and migration

Redirects

Mapping table
Path Location
/docs/lxd /docs/install-lxd
2 Likes

Hey guys. Who/which forum can I ask the following question.

Would it be appropriate to use mircoK8s for a production standalone server ?

Cheers,
Nate

Hi @intyig20,

Yes, MicroK8s is perfectly fine for a production server.

You can post questions on this forum and tag them with MicroK8s so we get notified.

Thanks

Hi,

Iā€™m new to microk8s and kubernetes, I started to read the doc yesterday and I may have spotted a problem :
In the fifth step (deploy an app), the command : microk8s kubectl create deployment return an error (Error: required flag(s) ā€œimageā€ not set).
I didnā€™t understand the error at first, but after going through other docs I came to understand that itā€™s incomplete, we should have something like this : microk8s kubectl create deployment nginx --image=nginx

Maybe the doc could be updated with a compete deployment command with a demo app or something, as it could be difficult to overcome for absolute beginners.

Thanks

I have seen this statement in the blog as well :

What is MicroK8s?

MicroK8s is a powerful, lightweight, reliable production-ready Kubernetes distribution.

And in the home of microk8s.io:

High availability K8s New

Low-ops, minimal production Kubernetes,
for devs, cloud, clusters, workstations, Edge and IoT.

but itā€™s not in the headline of this category:

Is there a reason that the official docs keeps a low-profile if itā€™s in fact considered production ready?

Can we put a note on here about the limitations of storage. The add-on only works with a single node. Not clusters, at least not very well once you get into more complex stuff.

please add a completely working example of how to use microk8s in production
now I run this commands in a new server before begin deploy apps
sudo snap install microk8s --classic
microk8s enable dashboard dns registry ingress metrics-server storage
microk8s kubectl create namespace cert-manager
microk8s kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/nginx-0.26.1/deploy/static/mandatory.yaml
microk8s kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/nginx-0.26.1/deploy/static/provider/cloud-generic.yaml
microk8s kubectl apply --validate=false -f https://github.com/jetstack/cert-manager/releases/download/v0.12.0/cert-manager.yaml
microk8s kubectl get pods --namespace cert-manager

Thanks for your use case. We may be doing some work to tidy up ā€˜defaultā€™ add-ons which will be automatically added which will make it easier to manage deploys. Beyond that, MicroK8s remains adaptable to the userā€™s needs, so there isnā€™t a set way to create a production deployment, although I take your point that we could add examples.

Hi, I am new to kubernets and Microk8s. I created an VM in ubuntu(18.0) and installed microk8s. I using add-ons called metallb also enabled the metallb add-on. the kubeconfig yaml file is getting created, but the problem the server address is my NAT address, its not allocating the mentioned ip address for the load-balancer. so its not accessible external address. Any help why this is happening. ?.

thank you

when you say

can you add any details - is this Virtual Box, LXD? What is the host OS?

Hi, its the virtual box. and the os is linux. I also face other error. the connection to the server localhost:8080 was refused - did you specify the right host or port?. When I searched on this error its mentioned kubectl file would not have been present . so I tried to run the following command.

mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
but admin.conf file is not present. Not sure how to get it

In VirtualBox, did you set the Network to Bridged Networking?

If you are running in Linux, it is probably easier to follow the LXD install instructions - will run faster and use fewer resources