If I’m rebuilding inside a cluster, rebuild only succeeds if i run it against the exact cluster member where the container is running, everything else gives a storage failure error
$ lxc ls auatest2
+----------+---------+------+------+-----------+-----------+----------+
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS | LOCATION |
+----------+---------+------+------+-----------+-----------+----------+
| auatest2 | STOPPED | | | CONTAINER | 0 | lxd13 |
+----------+---------+------+------+-----------+-----------+----------+
$ lxc rebuild c8 lxd11:auatest2
Error: Failed instance rebuild: Failed rebuilding instance from image: Instance storage pool not found
Exit Code: 1
$ lxc rebuild c8 lxd13:auatest2
is this intended? shouldn’t the cluster member that got the call forward it to wherever the container is? or at least can there be a --target? My cluster endpoint haproxies to the random cluster member and this is then a bit of a problem for me, as you can imagine
also would it be possible to support all the parameters as lxc init, especially --profile and --config? My use case is that I don’t want to necessarrily rebuild with the same config, but I want to keep old snapshots for easier rollback. Right now I’m doing
lxc mv container container-old
lxc init container --config .. --profile ...
in case of rollback:
lxc rm -f container
lxc mv container-old container
and that is messy as it creates a bunch of containers that clutter lxc lists and can be accidentally started, etc. Instead i want to be able to do something like this:
lxc snapshot container old
lxc rebuild container --profile --config ...
and then in case of rollback
lxc restore container old
much cleaner if you ask me
regards,