Skip to content
New issue

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

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

Already on GitHub? # to your account

Move persistent disk logic from Lima to alpine-lima #131

Open
jandubois opened this issue Oct 25, 2024 · 0 comments
Open

Move persistent disk logic from Lima to alpine-lima #131

jandubois opened this issue Oct 25, 2024 · 0 comments

Comments

@jandubois
Copy link
Member

Moving this to a new issue because I want to close #123

I assume you mean the cidata boot scripts and not the logic in Go here.

I think some of the logic (like 04-persistent-data-volume) should be moved to the distro instead of being hard-coded in Lima (e.g. I sometimes wanted an Alpine VM without the persistent disk).

This wasn't possible originally, but I think we have most of the pieces in place to implement something like

additionalDisks:
- name: data
  internal: true

provision:
- mode: boot
  script: lima-setup-peristent-disk /etc /home /root /tmp /usr/local /var/lib

The internal: true setting would create a non-shared additional disk that would be created and deleted automatically as the instance is created/deleted.

And we would need to implement mode: boot support for Alpine.

Then the script can be included in the ISO and you can have templates with and without persistent disks, and could even configure which directories you want to persist.

We would still have to keep the current boot scripts for backwards compatibility with older existing instances, so we would also need a mechanism to disable the builtin support.

Originally posted by @jandubois in #123 (comment)

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant