bug: run umoci in --rootless mode
Metadata
Current evaluation
No evaluation has been recorded for this issue yet.
Issue body
https://github.com/canonical/rockcraft/blob/041e31375a27af9ac74ff31625076f5bdd68c469/rockcraft/oci.py#L185
This is not a problem for lxc-based builds, but when running Rockcraft with a nonroot user and with `--destructive-mode`, the following will happen:
> Failed to copy image: Command '['/snap/rockcraft/1907/bin/umoci', 'unpack', '--image', '/home/ubuntu/images/ubuntu:22.04', '/home/ubuntu/bundles/ubuntu-22.04']' returned non-zero exit status 1. (• umoci encountered a permission error: maybe --rootless will help?
> ⨯ create runtime bundle: unpack rootfs: chown rootfs: lchown /home/ubuntu/bundles/ubuntu-22.04/rootfs: operation not permitted)
Evaluation history
No evaluation history available.