Homelab Docker Host setup on ProxMox LXC
System Requirements:
- LXC Container system
- Debian 10+
- 1024MB Memory
- 1 Core
Enable nesting features in the Proxmox VE Container Configuration
- The
/etc/pve/lxc/<CTID>.conf
files stores container configuration, whereCTID
is the numeric ID of the given container.
# On the proxmox server
# e.g. where my LXC ID is 101
nano /etc/pve/lxc/101.conf
- insert at the bottom of the file:
features: keyctl=1,nesting=1
-
Reboot container
-
Install useful tools
# Run as root
apt update
apt install -y dnsutils net-tools sudo jq
- Install Docker
# Run as root
apt-get update
sudo apt-get remove docker docker-engine docker.io containerd runc
sudo apt-get -y install
apt-transport-https
ca-certificates
curl
gnupg
lsb-release
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
echo
"deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg\] https://download.docker.com/linux/debian
$(lsb\_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt-get update
sudo apt-get install -y docker-ce docker-ce-cli containerd.io docker-compose
- Confirm you can run a docker container:
#̲# Start Docker
sudo systemctl enable docker
Other Tips
- To ensure containers start on boot add the following setting in your
docker-compose.yml
:restart: always