This repository contains Armbian extensions focused on:
- OTA updates (Recovery OTA / A/B Partition OTA)
- Disk encryption (LUKS) with automatic unlock (OP-TEE)
seeed_armbian_extension.sh is the extension entry script. It only enables sub-extensions based on environment variables and does not implement core features directly.
armbian-ota/: OTA packaging and runtime toolsrk_secure-disk-encryption/: encryption and auto-decryption implementation
| Feature | Key Flags | Description |
|---|---|---|
| Recovery OTA | OTA_ENABLE=yes and AB_PART_OTA unset |
Single-system OTA applied in initramfs after reboot |
| A/B OTA | OTA_ENABLE=yes AB_PART_OTA=yes |
Dual-slot OTA with rollback support |
| LUKS root | CRYPTROOT_ENABLE=yes |
Enables encrypted root filesystem |
| Auto-decrypt | CRYPTROOT_ENABLE=yes RK_AUTO_DECRYP=yes |
Automatically unlocks encrypted root at boot |
Current relevant logic in seeed_armbian_extension.sh:
- When
CRYPTROOT_ENABLE=yes, it enablesrk_secure-disk-encryption/rk-cryptroot-verbosity(setsverbosity=7inarmbianEnv.txtfor early boot troubleshooting). - It validates
CRYPTROOT_PASSPHRASElength when encryption is enabled; the passphrase must be exactly 64 characters or the build exits with error. - When
CRYPTROOT_ENABLE=yes RK_AUTO_DECRYP=yes:CRYPTROOT_SSH_UNLOCK=no- Enables
rk_secure-disk-encryption/rk-auto-decryption-disk
- When
OTA_ENABLE=yes, it enablesarmbian-ota/ota-support.
export OTA_ENABLE=yes
./compile.shexport OTA_ENABLE=yes
export AB_PART_OTA=yes
./compile.shexport CRYPTROOT_ENABLE=yes
export RK_AUTO_DECRYP=yes
export CRYPTROOT_PASSPHRASE='your-64-char-passphrase'
./compile.shUnified command entry:
armbian-ota start --mode=recovery <ota-package.tar.gz>
armbian-ota start --mode=ab <ota-package.tar.gz>
armbian-ota status
armbian-ota mark-success
armbian-ota rollbackCurrent implementation highlights:
- Detects auto-decrypt path via
PARTLABEL=security. - Mounts and updates rootfs via
/dev/mapper/armbian-root. - If a separate
bootpartition exists and payload includesboot.tar.gz, boot partition OTA is also applied. - Uses a two-step tar extraction strategy (metadata mode + plain fallback) and prints explicit errors on failure.
ota-support.sh generates:
rootfs.tar.gz(required)rootfs.sha256boot.tar.gz(when a separate boot partition exists)boot.sha256ota_manifest.envota_manifest.txtota_tools/(offline/fallback runtime tools)
seeed_armbian_extension/
├── seeed_armbian_extension.sh # Entry: extension orchestration only
├── armbian-ota/
│ ├── ota-support.sh # OTA build and packaging logic
│ ├── runtime/ # Unified armbian-ota CLI and backends
│ ├── recovery_ota/ # Recovery OTA (initramfs apply)
│ └── ab_ota/ # A/B OTA userspace/systemd
└── rk_secure-disk-encryption/
├── rk-cryptroot-verbosity.sh # Sets armbianEnv verbosity in cryptroot builds
├── rk-auto-decryption-disk.sh # Auto-decryption workflow
└── auto-decryption-config/ # initramfs hook and decrypt scripts
- Keep
seeed_armbian_extension.shfocused on flag checks andenable_extensiondispatching. - Put feature implementation in sub-extension scripts (for example
rk-cryptroot-verbosity.sh,ota-support.sh).
- OTA details:
armbian-ota/README.md