This crate is deprecated as the long-term source of distro declarations.
Migration direction:
distro-spec/src/{levitate,acorn,iuppiter,ralph}->distro-variants/*- Shared runtime/build policy ->
distro-builder - Test-only assertions/checklists ->
testing/*
Why deprecated:
- We need tight conformance boundaries in
distro-variants/*. - Cross-crate duplication between per-OS crates and
distro-speccauses drift. - Shared invariants must be enforced once (in
distro-builder/contract flow), not copied per distro module.
Shared-module destination analysis is tracked in:
SHARED_MIGRATION_MAP.md
Shared constants for LevitateOS installation. Partition layouts, user specs, boot configuration, chroot bind mounts.
Beta. Used by leviso, recstrap, install-tests.
| Implemented | Stubbed |
|---|---|
| LevitateOS specs (Rocky/systemd) | AcornOS specs (Alpine/OpenRC) |
| Partition layouts | |
| User specs | |
| Boot entry types | |
| Chroot bind mounts |
use distro_spec::levitate;
// Default user spec
let user = levitate::default_user("alice");
// Boot entry
let entry = levitate::default_boot_entry();
// Constants
use distro_spec::{CHROOT_BIND_MOUNTS, EFI_PARTITION_SIZE_MB};LevitateOS specs: Rocky Linux packages, systemd, glibc.
AcornOS specs: Alpine packages, OpenRC, musl. Stubbed, not implemented.
| Module | Contents |
|---|---|
partitions |
PartitionLayout, EFI_PARTITION_SIZE_MB |
users |
UserSpec, MIN_UID, SUDOERS_WHEEL_LINE |
chroot |
BindMount, CHROOT_BIND_MOUNTS |
boot |
BootEntry, LoaderConfig |
[dependencies]
distro-spec = { path = "../distro-spec", default-features = false }Disable std feature for embedded/bootloader contexts.
leviso- Uses paths, boot configrecstrap- Uses canonical EROFS rootfs search pathsinstall-tests- Uses all specs for verification
- AcornOS module exists but is not implemented
- No runtime validation of specs
- Changes here require updates to all consumers
cargo build
cargo testMIT