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

feat: allow user to specify the image to reset to #3148

Open
jimmykarily opened this issue Jan 27, 2025 · 2 comments
Open

feat: allow user to specify the image to reset to #3148

jimmykarily opened this issue Jan 27, 2025 · 2 comments
Labels
enhancement New feature or request triage Add this label to issues that should be triaged and prioretized in the next planning call

Comments

@jimmykarily
Copy link
Contributor

For installation it's possible to specify which image should be used using:

install:
  source: oci:your_image_here

This works because of the way we parse this key but we don't do anything similar when constructing the ResetSpec.

It's useful to have this option because on public cloud, the system is "installed" by performing an auto-reset. Users can specify the image they want to install by booting any cloud image we push to that provider and setting the image to reset to. This way we don't need to push all possible flavors and such.

Problems with this approach:

  • The parent image defines the recovery partition size so if the image specified by the user is bigger, it might not fit.
  • We calculate the rest of the sizes based on the "parent" image but this one we can probably fix when we implement this feature.

Is your feature request related to a problem? Please describe.

Describe the solution you'd like

Describe alternatives you've considered

Additional context

@jimmykarily jimmykarily added enhancement New feature or request triage Add this label to issues that should be triaged and prioretized in the next planning call labels Jan 27, 2025
@Itxaka
Copy link
Member

Itxaka commented Jan 27, 2025

IIRC, you could override the source during reset by setting it at the image level?

reset:
    system:
      uri: oci:whatever

@jimmykarily
Copy link
Contributor Author

turns out, this works ^. It's because we do this black magic here: https://github.com/kairos-io/kairos-agent/blob/3412d7a2a2313a8d4ba42a264f11a681f016aaea/pkg/types/v1/common.go#L83-L90

I any case. We should probably find a better way to set the installation/reset/upgrade image so that it's consistent and more intuitive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request triage Add this label to issues that should be triaged and prioretized in the next planning call
Projects
Status: No status
Development

No branches or pull requests

2 participants