Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LXD: Fix start and stop for FROZEN instances #13452

Merged
merged 4 commits into from
May 22, 2024

Conversation

MggMuggins
Copy link
Contributor

@MggMuggins MggMuggins commented May 6, 2024

This was fixed in incus with the same patch as in #12493

Not sure if this warrants an API extension: if users were expecting start to fail on frozen instances, then this does break that workflow. Happy to add one if needed.

@MggMuggins MggMuggins requested a review from tomponline as a code owner May 6, 2024 22:42
@MggMuggins MggMuggins force-pushed the frozen-instance-stop branch from e26e22f to 10ae19a Compare May 6, 2024 22:58
@tomponline
Copy link
Member

@MggMuggins if you are using patches from Incus then you need to cherry pick specific commits to maintain attribution and add the Apache 2.0 license footer to the commit message (see link to doc in lxd private mm channel).

@MggMuggins
Copy link
Contributor Author

MggMuggins commented May 9, 2024

@tomponline This does not use changes from incus; the approach incus took was to add a resume/unfreeze subcommand; they were rejected for LXD in December. This PR changes the meaning of start in the API from "start if stopped" to"start if stopped or frozen". There's no common code between this and that change.

lxd/instance_state.go Outdated Show resolved Hide resolved
Copy link
Member

@tomponline tomponline left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please can we have tests added for this.

lxc/action.go Outdated Show resolved Hide resolved
Fixes canonical#12578

Signed-off-by: Wesley Hershberger <wesley.hershberger@canonical.com>
Signed-off-by: Wesley Hershberger <wesley.hershberger@canonical.com>
Fixes canonical#12491

Signed-off-by: Wesley Hershberger <wesley.hershberger@canonical.com>
Signed-off-by: Wesley Hershberger <wesley.hershberger@canonical.com>
@MggMuggins MggMuggins force-pushed the frozen-instance-stop branch from 10ae19a to 1915d99 Compare May 13, 2024 20:19
@MggMuggins MggMuggins requested a review from tomponline May 13, 2024 22:13
Copy link
Member

@tomponline tomponline left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@tomponline tomponline merged commit bb3b99d into canonical:main May 22, 2024
29 checks passed
@MggMuggins MggMuggins deleted the frozen-instance-stop branch May 22, 2024 15:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants