Fix `buildkitd --group GROUP` issue when `/run/buildkit` already exists
and is owned by the root.
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
Often the socket is put into the directory /run/containerd.
When this directory does not exist, it gets created with the
default uid/gid and permission 0660. When the user has specified
a uid or gid, this should be used to set the ownership of that
parent directory and the permissions should be 0770. This worked
in a previous version of containerd but regressed after a refactor.
Signed-off-by: Derek McGowan <derek@mcgstyle.net>
Updates the filemode on the grpc socket to have group write
permission which is needed to perform GRPC. Additionally, ensure
the run directory has the specified group ownership and has group
read and enter permission.
Signed-off-by: Derek McGowan <derek@mcgstyle.net>