LXC image copy/move within projects and hosts

I have projects with features.images: “true”.
How can I copy/move it to another project within same host? Also cant fetch that from other host. Whilst image list honors --project as source project, image copy cant take two --project flags (source/destination)

Feels like we need a --target-project in lxc image copy to align it with lxc copy and lxc storage volume copy.

Can you file a request at https://github.com/lxc/lxd/issues ?

already has a --target-project flag.

Same goes for instance creation.
lxc init or lxc launch using an image from another project. They accept --project flag as location to launch, but cant point to an image source being another project.

In this particular case, it’s also not possible at the API level. Instances must use images from their own project, so you’d need to first perform the copy.

Once the above issue Add --target-project to lxc image copy is sorted, sure can copy the image from one project to the other where the instance going to be created.
Still it is kind of waste, as images for all projects are all in one place storage.images_volume: pl/images in order to access one, need to copy it within same location but with another project tag!
As I followed your instruction of publishing virtual-machines after succeeded installation from CD, those published images are quite large, some 5-9 GB.
Need indeed copy them every time needed for another project?

Came looking for this today. Looks like the feature is implemented.

1 Like