Profile apply getting Error: Invalid expanded devices: Detect root disk device: No root device could be found

when i try to apply . aprofile to a container i get:
Error: Invalid expanded devices: Detect root disk device: No root device could be found

the profile is very simple:
config:
limits.cpu: “8”
limits.memory: 16GB
description: “”
devices: {}
name: develserver
used_by:

  • /1.0/containers/devel-cdn

but when i do lxc config edit container
and add it manually and save the config it’s ok.

Ignore my post…of course when calling apply you have to list all profiles not just the one you wish to add…

That’s right.

Examples:
  lxc profile assign foo default,bar
      Set the profiles for "foo" to "default" and "bar".

Both lxc profile assign and lxc profile apply work. I think that originally it was only lxc profile apply but was changed to assign. And apply was kept for backward compatibility.