Why the K3s and Fedora Server Combo is Worth Trying?
After six months of tinkering with K3s on an old Fedora Server tucked away in the corner of my desk, I realized one thing: You don’t need a massive server rig to learn Kubernetes. If you want to run side projects without shelling out money for the cloud or watching your control plane devour all your RAM, K3s is a lifesaver.
K3s is a lightweight version of Kubernetes developed by Rancher Labs. They stripped out redundant cloud drivers and bundled everything into a single binary file under 100MB. While original K8s needs nearly 2GB of RAM just to “breathe,” K3s runs stably on about 512MB.
As for Fedora Server, it has been my go-to distro for over two years. It provides the latest Kernel, excellent Btrfs support, and a very tight SELinux security system. The combination of a modern distro and an optimized tool like K3s delivers a very smooth experience for developers.
System Preparation
You need a Fedora Server machine (latest version 39 or 40). Ensure the machine has at least 1 vCPU and 1GB of RAM for the most comfortable operation.
1. Update the System
Never skip this step to avoid package conflicts:
sudo dnf update -y
2. Smart Firewall Configuration
Fedora blocks most ports by default. Instead of disabling the firewall entirely (which is unsafe), we only open exactly what is needed. K3s requires port 6443 for the API Server and several ports for network plugins:
# Open API Server and Kubelet ports
sudo firewall-cmd --permanent --add-port=6443/tcp
sudo firewall-cmd --permanent --add-port=10250/tcp
# Open port for Flannel VXLAN (default)
sudo firewall-cmd --permanent --add-port=8472/udp
# Apply changes
sudo firewall-cmd --reload
3. Handling SELinux Correctly
Many guides suggest disabling SELinux, but I recommend against it. We will install policies so K3s can run securely without being blocked by the system:
sudo dnf install -y container-selinux selinux-policy-base
sudo dnf install -y https://rpm.rancher.io/k3s/stable/common/centos/7/noarch/k3s-selinux-1.5-1.el7.noarch.rpm
Installing K3s in a Snap
Installing K3s is incredibly simple. You just need to execute the script from Rancher; it will automatically detect your system and configure everything:
curl -sfL https://get.k3s.io | sh -
It takes about 60 seconds for the script to download the binary and set up the systemd service. Once finished, check if the cluster is “alive”:
sudo systemctl status k3s
If you see the active (running) status in green, congratulations, your cluster is ready to serve.
Configuring Access for Standard Users
By default, the k3s.yaml file is only readable by root. To run kubectl commands as a regular user without sudo, perform the following commands:
mkdir ~/.kube
sudo cp /etc/rancher/k3s/k3s.yaml ~/.kube/config
sudo chown $USER:$USER ~/.kube/config
chmod 600 ~/.kube/config
echo "export KUBECONFIG=~/.kube/config" >> ~/.bashrc
source ~/.bashrc
Now, try checking the nodes with the command: kubectl get nodes. You should see your Fedora node in the Ready state.
Deploying a Sample Application
Let’s try deploying an Nginx web server to test the cluster’s orchestration capabilities. K3s comes with Traefik pre-installed as an Ingress Controller, making it extremely easy to expose applications to the internet.
Create an nginx-demo.yaml file with specific resource limits (best practice):
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-app
spec:
replicas: 2
selector:
matchLabels:
app: nginx
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:alpine
resources:
limits:
memory: "128Mi"
cpu: "200m"
ports:
- containerPort: 80
---
apiVersion: v1
kind: Service
metadata:
name: nginx-svc
spec:
selector:
app: nginx
ports:
- port: 80
targetPort: 80
Deploy it using: kubectl apply -f nginx-demo.yaml. After a few seconds, you will see two Nginx pods running smoothly.
Practical Tips After 6 Months
Managing a small cluster requires its own tricks to keep the system from freezing unexpectedly:
- Don’t Forget Swap: Fedora Server uses zRAM. However, if you run many apps, you should create an additional 1-2GB swap file on the disk to avoid Out of Memory (OOM) situations.
- Use K9s: This tool has been a lifesaver for me. Instead of typing long kubectl commands, K9s provides an intuitive terminal UI to view logs and manage pods five times faster.
- Updates: When you want to upgrade K3s, simply run the original installation script again. The system will automatically update the binary without interrupting your running applications.
Conclusion
K3s on Fedora Server is an excellent choice for balancing performance and resources. You get a real Kubernetes environment for learning and deploying personal projects with almost zero operating costs.
If you encounter any issues with networking or SELinux permissions during installation, feel free to leave a comment below. Let’s troubleshoot together!

