Skip to content

[11/n] [sled-agent] move around ZoneImageFileSource logic #8235

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

Conversation

sunshowers
Copy link
Contributor

  • Move ZoneImageFileSource to illumos-utils and use it in the zone image builder.
  • Move default file name logic to sled-agent-zone-images, since it cares about that in the context of mupdate override logic.

Depends on:

Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1

[skip ci]
Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1

[skip ci]
Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1

[skip ci]
Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1

[skip ci]
Created using spr 1.3.6-beta.1
@@ -2003,7 +2004,7 @@ impl InstanceRunner {
.with_log(self.log.clone())
.with_underlay_vnic_allocator(&self.vnic_allocator)
.with_zone_root_path(root)
.with_zone_image_paths(&["/opt/oxide".into()])
.with_file_source(&ramdisk_file_source("propolis-server"))
Copy link
Contributor

Choose a reason for hiding this comment

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

Could ramdisk_file_source take a ZoneType or ZoneKind instead of a bare str?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah no because propolis-server isn't an Omicron zone (what ZoneType and ZoneKind represent). Will add a comment here.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah right. That's unfortunate.

@sunshowers sunshowers changed the base branch from sunshowers/spr/main.11n-sled-agent-move-around-zoneimagefilesource-logic to main June 18, 2025 20:53
Created using spr 1.3.6-beta.1
@sunshowers sunshowers enabled auto-merge (squash) June 18, 2025 20:53
@sunshowers sunshowers merged commit c9226bb into main Jun 18, 2025
16 checks passed
@sunshowers sunshowers deleted the sunshowers/spr/11n-sled-agent-move-around-zoneimagefilesource-logic branch June 18, 2025 23:19
sunshowers added a commit that referenced this pull request Jun 19, 2025
…t error (#8237)

For mupdate overrides, in order to be safe, we must know that the data
stored in the JSON is consistent with the images stored on disk. We
currently apply this logic to install dataset hashes, and will apply it
to artifact hashes in the future.

Questions:

* [x] ~~Should we apply this logic to more critical zones like the
switch zone? They're always going to be part of the ramdisk maybe?~~ We
unconditionally succeed for RAMdisk zones, and in particular the switch
zone, now.
* [ ] How does this interact with config-reconciler work? On error, that
would permanently be blocked it seems to me. Note: we decide errors
per-zone now.
* [ ] We ask for the boot zpool to be passed in but also cache it as
part of constructing the info... how do we reconcile the relative
presence or absence of this info?

Depends on #8235.
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.

3 participants