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

frzr refactor #61

Merged
merged 26 commits into from
Jul 24, 2024
Merged

frzr refactor #61

merged 26 commits into from
Jul 24, 2024

Conversation

NeroReflex
Copy link
Contributor

@NeroReflex NeroReflex commented Jun 20, 2024

This is a frzr refactor that has been a work-in-progress for months.

Main points are:

  • it supports resuming from hibernation and swap partitions
  • it can report progress to an external (graphical) tool so a gui can be developed
  • can work with any systemd-based distros
  • improved errors handling and debuggability of issues
  • allows for multiple kernels being installed in a deployment and create an entry with the right name
  • automatically recreate boot entries for old and new deployments
  • deployment is more reliable as the switch to a new deployment to boot is only done if no errors occurred
  • can easily install kernels that can be used with any installed deployment provided the deployment is compatible with the new frzr (one can still boot and use an old one if initramfs contains all needed drivers)
  • the deployment that has deployed the new one will be left bootable even if no errors occurred, but it won't be the default selection (so that in case of problems one can always boot the previous one)
  • device-quirks have been separated from frzr as frzr can deal with any distro now
  • frzr now supports any initramfs and is not hardcoded to mkinitcpio
  • unlock has been made distro-dependent
  • technically it can be used to convert any systemd-boot system to a chimeraos system
  • it is now possible to develop a tool to restore a deployment to "factory" after that deployment has been unlocked (without downloading anything)
  • delta updates can be redistributed
  • supports a format that can be streamed directly to btrfs receive and will improve build space on github by a lot
  • many more I am sure I just forgot

@NeroReflex
Copy link
Contributor Author

AUR will need to be fixed too, to know how check this: https://github.com/NeroReflex/chimeraos/tree/master/pkgs/frzr
The 99-frzr-kernel-install.hook will ensure that each time a kernel is installed via pacman bootloader entries are regenerated.

This will make even a better experience than stock archlinux in this regard

@NeroReflex
Copy link
Contributor Author

This refactor is a step forward towards #60
This also fixes #22 completely when combined with a systemd-based initramfs
#38 this will need to be moved to device-quirks (it's a work-in-progress currently)

@NeroReflex
Copy link
Contributor Author

Just for the record this is fully retro - compatible with older deployments. One can jump between older and newer released. The frzr kernel tool won't really work and device quirks will have to be triggered manually after the update when dowgrading.
If the new image is done correctly an old frzr can jump to a newer-style image.

@Samsagax
Copy link
Contributor

I guess you should refactor the tests so they make sense with this new overhaul. The main one is the release image retrieval process.

@NeroReflex
Copy link
Contributor Author

I guess you should refactor the tests so they make sense with this new overhaul. The main one is the release image retrieval process.

I have never looked into those, maybe @ruineka is more familiar? I saw he started doing tests

@ruineka
Copy link
Collaborator

ruineka commented Jun 21, 2024

I guess you should refactor the tests so they make sense with this new overhaul. The main one is the release image retrieval process.

I have never looked into those, maybe @ruineka is more familiar? I saw he started doing tests

We just need to update the functions to match the new methods and give it dummy information and compare the result. You can take a look into tests/run.sh

@NeroReflex
Copy link
Contributor Author

The main one is the release image retrieval process.

I have set up a test where the current stable is installed on a loopback device that starts as file copy of /dev/zero. If you have other ideas let me know!

Added a test that creates an archlinux deployment and installs it
Adding a test for the deletion algorithm I discovered that did not work
in installer mode: fixed
Fix installing images from file
@ruineka ruineka merged commit fd1cd3b into ChimeraOS:master Jul 24, 2024
1 check passed
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.

4 participants