DEV Community

Alex Spinov
Alex Spinov

Posted on

K3s Has a Free Lightweight Kubernetes That Runs on a Raspberry Pi

Kubernetes needs 4GB RAM minimum. K3s runs a full Kubernetes cluster in 512MB — certified by CNCF, production-ready, and packaged as a single 70MB binary.

What K3s Removes

K3s strips Kubernetes of components most people do not need:

  • Legacy cloud provider plugins
  • Non-default storage drivers
  • Docker dependency (uses containerd)
  • Heavy alpha/experimental features

What remains is 100% Kubernetes API compatible — your kubectl commands, Helm charts, and manifests work unchanged.

Install (30 Seconds)

# Server (master node)
curl -sfL https://get.k3s.io | sh -

# Check it works
kubectl get nodes
# NAME    STATUS   ROLES                  AGE   VERSION
# node1   Ready    control-plane,master   30s   v1.30+k3s1
Enter fullscreen mode Exit fullscreen mode

One command. Full Kubernetes. Under 30 seconds.

Add Worker Nodes

# Get the token from the server
cat /var/lib/rancher/k3s/server/node-token

# On worker nodes
curl -sfL https://get.k3s.io | K3S_URL=https://server-ip:6443 K3S_TOKEN=your-token sh -
Enter fullscreen mode Exit fullscreen mode

What Is Included

K3s bundles everything you need:

Component Included Standalone alternative
Container runtime containerd Docker
CNI (networking) Flannel Calico, Cilium
Ingress Traefik Nginx Ingress
Load Balancer ServiceLB MetalLB
Storage Local-path Longhorn
DNS CoreDNS
Helm controller Yes

Deploy Your App

# app.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  name: my-api
spec:
  replicas: 3
  selector:
    matchLabels:
      app: my-api
  template:
    metadata:
      labels:
        app: my-api
    spec:
      containers:
        - name: api
          image: my-registry/my-api:latest
          ports:
            - containerPort: 3000
          resources:
            requests:
              memory: "64Mi"
              cpu: "100m"
            limits:
              memory: "128Mi"
              cpu: "250m"
---
apiVersion: v1
kind: Service
metadata:
  name: my-api
spec:
  type: ClusterIP
  ports:
    - port: 80
      targetPort: 3000
  selector:
    app: my-api
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: my-api
spec:
  rules:
    - host: api.example.com
      http:
        paths:
          - path: /
            pathType: Prefix
            backend:
              service:
                name: my-api
                port:
                  number: 80
Enter fullscreen mode Exit fullscreen mode
kubectl apply -f app.yaml
Enter fullscreen mode Exit fullscreen mode

Resource Usage

K8s (kubeadm) K3s K0s
Server RAM 2-4 GB 512 MB 1 GB
Binary size ~300 MB 70 MB 170 MB
Startup time 2-5 min 30 sec 1 min
Install complexity High One command One command
CNCF certified Yes Yes Yes

Perfect For

  • Edge computing — IoT devices, retail locations
  • Development — local k8s that does not eat your RAM
  • Raspberry Pi clusters — ARM64 support built-in
  • CI/CD — spin up k8s for integration tests
  • Home lab — run production workloads on old hardware
  • Small businesses — production k8s on a $5 VPS

Need Kubernetes infrastructure or automation? I build DevOps tools and data solutions. Email spinov001@gmail.com or check my Apify tools.

Top comments (0)