Skip to content

Instantly share code, notes, and snippets.

@kvaps
Last active September 29, 2022 14:33
Show Gist options
  • Save kvaps/25f730e0ec39dd2e5749fb6b020e71fc to your computer and use it in GitHub Desktop.
Save kvaps/25f730e0ec39dd2e5749fb6b020e71fc to your computer and use it in GitHub Desktop.
Run Kubernetes as Proxmox container

Add to your contaier config /etc/pve/lxc/XXX.conf:

lxc.apparmor.profile: unconfined
lxc.cgroup.devices.allow: a
lxc.cap.drop: 
lxc.mount.auto: proc:rw sys:rw

Last verisons of kubernetes requires also shared filesystem, so add

mount --make-rshared /

into your /etc/rc.local inside container

@aug70
Copy link

aug70 commented Jun 4, 2020

W0604 21:04:57.186291 190 configset.go:202] WARNING: kubeadm cannot validate component configs for API groups [kubelet.config.k8s.io kubeproxy.config.k8s.io]
[init] Using Kubernetes version: v1.18.3
[preflight] Running pre-flight checks
[WARNING IsDockerSystemdCheck]: detected "cgroupfs" as the Docker cgroup driver. The recommended driver is "systemd". Please follow the guide at https://kubernetes.io/docs/setup/cri/
[WARNING FileExisting-tc]: tc not found in system path
[preflight] The system verification failed. Printing the output from the verification:
KERNEL_VERSION: 5.4.41-1-pve
DOCKER_VERSION: 18.09.1
DOCKER_GRAPH_DRIVER: overlay2
OS: Linux
CGROUPS_CPU: enabled
CGROUPS_CPUACCT: enabled
CGROUPS_CPUSET: enabled
CGROUPS_DEVICES: enabled
CGROUPS_FREEZER: enabled
CGROUPS_MEMORY: enabled
error execution phase preflight: [preflight] Some fatal errors occurred:
[ERROR SystemVerification]: failed to parse kernel config: unable to load kernel module: "configs", output: "modprobe: FATAL: Module configs not found in directory /lib/modules/5.4.41-1-pve\n", err: exit status 1
[preflight] If you know what you are doing, you can make a check non-fatal with --ignore-preflight-errors=...
To see the stack trace of this error execute with --v=5 or higher

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment