refactor!: install the feeder under the /opt/airplanes FHS layout#144
Merged
Conversation
Payload moves under /opt/airplanes/current, state under /var/lib/airplanes/runtime, units under /etc/systemd/system — matching the image layout. Upgrades from the old /usr/local/share/airplanes layout relocate automatically; /etc/airplanes is preserved. BREAKING CHANGE: the install layout changed; feeders on the old layout are relocated on the next update, preserving feeder identity.
Phase 1 installs origin/main, whose scripts hardcode /usr/local/share/airplanes; only the post-candidate assertions use the new /opt + /var/lib + /run layout.
The /etc/airplanes/image-install marker only exists on overlay images, so a legacy ROM (baked /usr/bin/airplanes-feeder, pre-marker) was misclassified as a manual install and dropped into interactive setup on update. Detect the legacy binary too — a read, not a /usr/bin write — gated on a present config source.
Legacy images (baked /usr/bin/airplanes-feeder, /boot config) lack the image-install marker. Restore that signal in the feed-binary resolver and the daemon/CLI config readers, keep the apl-feed symlink relative, and broaden the pre-FHS cleanup.
The legacy mounted-image and QEMU boot smokes still asserted the pre-FHS /usr/local paths and flat /run state dirs. Point them at /opt/airplanes/current, the $STATE version stamps, and the nested /run/airplanes/{feed,mlat} state files.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Moves the feeder's standalone install onto the FHS layout the image already uses: payload under
/opt/airplanes/current, mutable state under/var/lib/airplanes/runtime, and systemd units under/etc/systemd/system, instead of the old/usr/local/share/airplanestree,/libunits, and/usr/binbinary. The result is one install layout whether the feeder came from the image or a manual install.Feeders on the previous layout are migrated automatically on their next update: the new layout is installed, the feeder UUID is carried into
/etc/airplanes/feeder-id, and the old tree and units are removed./etc/airplanesis never touched, so identity and configuration are preserved.