Open mr-cal opened 4 months ago
Thank you for reporting us your feedback!
The internal ticket has been created: https://warthogs.atlassian.net/browse/CRAFT-2619.
This message was autogenerated
From the LXD team (@tomponline):
The CLI output isn't guaranteed to be stable, so perhaps a better way is to use the API directly, i.e.
lxc query /1.0 | jq .environment.server_version
"5.21.1"
The API version server_version didn't change, and instead we added a new server_lts field.
so querying the API directly is the right way to go
Just an FYI, that currently there is a bug in lxd-installer
(a kind of shim to dynamically install LXD's snap if it's not present) that prevents the suggested detection mechanism from working.
Until that bug fix is propagated to all supported releases, please make sure to test on systems where the LXD snap is installed rather than rely on lxd-installer
to pull it.
What needs to get done
If LXD version parsing fails, craft-providers should catch the failure and log a warning.
Why it needs to get done
LXD recently changed their version naming convention, which broke craft-providers and had to be fixed via #532. This check should be more robust.