project-pegaprox icon indicating copy to clipboard operation
project-pegaprox copied to clipboard

[Feature] Create CT wizard for Proxmox missing keyctl feature toggle (Docker-in-LXC breaks silently

Open Sidirius opened this issue 7 months ago • 1 comments

Problem

The "Create Container" wizard for Proxmox nodes exposes nesting as a feature toggle, but not keyctl. Both are required for running Docker inside an unprivileged LXC. A container created through PegaProx with the nesting box ticked will start, but Docker will run into kernel keyring / overlay2 permission errors at runtime (depending on the image and workload, sometimes only on the first docker run).

The native Proxmox web UI exposes both toggles side by side in the Features tab of the Create CT wizard, so users who switch from the native UI to PegaProx will silently lose the keyctl setting and not notice until Docker misbehaves.

Reproduction

  1. PegaProx → cluster → node → Create CT
  2. Select a Debian template (tested with debian-13-standard), pick unprivileged, default resources
  3. Features section: only nesting is available — there is no keyctl checkbox
  4. Finish the wizard, start the container, install and run Docker
  5. Symptoms will surface when Docker uses overlay2 / needs session keyrings

Workaround on the host, after create:

pct set --features nesting=1,keyctl=1 pct reboot

Suggested fix

Expose keyctl alongside nesting in the Features section of the Create CT wizard (and ideally in the "Options → Features" edit dialog of an existing CT too). The PVE REST endpoint POST /nodes/{node}/lxc already accepts features=nesting=1,keyctl=1 so no backend work should be needed — it's a UI additions only.

Also fuse=1 and mount=<types> would be nice to have in the same section for feature parity with the native wizard, though those are lower priority than keyctl which is a Docker-in-LXC blocker.

Environment

  • PegaProx version: 26.04.1.6442 (running as Docker)
  • Proxmox VE: 8.x
  • Observed: 2026-04-09

Sidirius avatar Apr 09 '26 13:04 Sidirius

Good catch, you're right — keyctl is pretty much mandatory for Docker in unprivileged LXC and we should have had it from the start. Added keyctl and fuse toggles to the Create CT wizard in 25f9349, the backend already passes them through to the PVE API as features=nesting=1,keyctl=1.

mount types (nfs/cifs) are supported on the backend side too but didn't add a UI for it yet since it's more niche. Let me know if you need it.

Regards, Marcus

mkellermann97 avatar Apr 09 '26 15:04 mkellermann97