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

Release disk and validation test fixes #218

Merged
merged 4 commits into from
Jan 6, 2025

Conversation

yfyf
Copy link
Collaborator

@yfyf yfyf commented Jan 2, 2025

While backporting release disk to 2024.7.0 I realized the approach had a critical issue: the built disk would have optimized partition sizes based on the current system's image size. This meant that newer releases would potentially not fit in the system partition if they increase in size.

At first I attempted introducing various flag combos to the existing disk target to overcome this, but it became very confusing. So I decided it's best to split release-disk into a separate target. See the commit 46aced3 message for details.

I managed to also get rid of the top-level extraModules.

See also the PR for the backport of ./build release-disk to 2024.7.0: #217

Checklist

  • Changelog updated
  • Code documented
  • User manual updated

yfyf added 3 commits December 30, 2024 14:55
focus-shift based navigation was only added after 2024.7.0
Earlier release disk build had a critical problem: the built disk would
have optimized partition sizes based on the current system's image size.
This meant that newer releases would potentially not fit in the system
partition if they increase in size.

To avoid this issue, we create disk images which have system partition
sizes equal to (default PlayOS size - 1 GiB). The 1GiB is subtracted as a
safety threshold to avoid releasing something that is very near max
capacitiy.

This gets rid of the extra top-level `extraModules` argument in
default.nix along the way.
@yfyf yfyf added the reviewable Ready for initial or iterative review label Jan 2, 2025
@yfyf yfyf requested a review from guyonvarch January 2, 2025 15:08
@yfyf
Copy link
Collaborator Author

yfyf commented Jan 2, 2025

Found a bug in the release workflow due to shallow git checkout, fixed in 75f4a5f.

Preview backported 2024.7.0 release: https://github.com/dividat/playos/releases/tag/2024.7.0-DISK

system = 1024 * 9; # 9 GiB (install-playos default - 1GiB)
data = 400; # 400 MiB (same as testing/disk/default.nix)
};
diskSizeMiB = 8 + partSizes."boot" + partSizes."data" + (partSizes."system" * 2) + 1;
Copy link
Member

Choose a reason for hiding this comment

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

In testing/disk/default.nix, diskSizeMiB is:

diskSizeMiB = 10 + bootPartSizeMiB + dataPartSizeMiB + systemPartSizeMiB*2;

Is there a reason to have 9 additional MiB here, and 10 in the other file?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Actually, I am not sure why I set it to 10 in testing/disk/default.nix - probably did it without much thought.

Here the +8MiB and +1MiB match the initial disk alignment sector size and extra space requirements as defined in install-playos.py.

Copy link
Member

Choose a reason for hiding this comment

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

Should we update testing/disk/default.nix and use the same logic, using 8 + … + 1?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I can do it in a separate PR, it is not related to these changes.

@guyonvarch guyonvarch added details needed Further information requested to better evaluate changes and removed reviewable Ready for initial or iterative review labels Jan 6, 2025
Copy link
Member

@guyonvarch guyonvarch left a comment

Choose a reason for hiding this comment

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

One minor question, looking good otherwise!

@yfyf yfyf added reviewable Ready for initial or iterative review and removed details needed Further information requested to better evaluate changes labels Jan 6, 2025
@guyonvarch guyonvarch merged commit 6f17ebc into dividat:main Jan 6, 2025
16 checks passed
@guyonvarch guyonvarch removed the reviewable Ready for initial or iterative review label Jan 6, 2025
@yfyf yfyf deleted the rel-validation-disk-fixes branch January 6, 2025 16:17
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