documentation incus
Tiré du blog de S. Robert et de la doc officielle
1 - installer incus
sudo -i
mkdir -p /etc/apt/keyrings/
curl -fsSL https://pkgs.zabbly.com/key.asc -o /etc/apt/keyrings/zabbly.asc
sh -c 'cat <<EOF > /etc/apt/sources.list.d/zabbly-incus-stable.sources
Enabled: yes
Types: deb
URIs: https://pkgs.zabbly.com/incus/stable
Suites: $(. /etc/os-release && echo ${VERSION_CODENAME})
Components: main
Architectures: $(dpkg --print-architecture)
Signed-By: /etc/apt/keyrings/zabbly.asc
EOF'
sudo apt udpate
sudo apt install incus
# configurer incus
incus admin init --minimal
# accès non-root
usermod -a -G incus-admin $USER
usermod -a -G incus $USER
2 - installer incus-ui
apt install incus-ui-canonical
incus config set core.https_address :8443
3 - la cli
# lister les images dispo
incus image list images:
incus image list images:debian/12/amd64
# instancier une image
# conteneur
incus launch images:debian/12/amd64 mon-instance # *mon-instance* est le nom donné à l'instance
# vm
incus launch images:debian/12/amd64 mon-instance-vm --vm
# limiter les ressources
incus launch images:debian/12/amd64 mon-instance --config limits.cpu=1 --config limits.memory=192MiB
# se connecter
incus shell mon-instance
# gérer
incus list
incus start mon-instance
incus stop mon-instance
incus delete mon-instance