cgmanager: fix 'attach' with "all" controller support
cgmanager: fix 'attach' with "all" controller support

"all" is not a supported keyword for cgmanager's get_pid_cgroup.
Pass the first mounted cgroup subsystem instead of passing "all" when
getting the container's cgorup to attach to.

Also, make sure that the target cgroup is in fact in all identical
cgroups before attaching with 'all".  If not, then we must attach to
each cgroup separately, or else we will not be in all the same cgroups
as the target container.

Signed-off-by: Serge Hallyn <3df611b026e4639bee8aef7a4beb2e39fcebb313@ubuntu.com>
Acked-by: Stéphane Graber <089afc6d81f66f1168a9849e15660feae286e024@ubuntu.com>

lxc/lxc-pkg-ubuntu,lxc/lxc-pkg-ubuntu,lxc/lxc-pkg-ubuntu