agama/rust/agama-autoinstall/Cargo.toml
Ladislav Slezák 98015b7d10
Autoload the installation profile from the medium root (jsc#PED-16010) (#3366)
## Problem

- When manually injecting an autoinstallatino profile into the
installation medium it is not used automatically. Agama should support
autoloading the profile from this location.

## Solution

- Autoload the installation profile from the medium root
- Use journal logging with more details in the autoinstallation CLI tool
(log to stdout when running manually)
- Not finding any profile in the predefined locations is not reported as
an error
- I refactored the code to share the part for initializing the logger

## Testing

- Tested manually
- You can inject an installation profile using this command:
  ```
xorriso -indev agama.iso -outdev agama-auto.iso -boot_image any replay
-map profile.json /autoinst.json
  ```
Where `agama.iso` is the input ISO, `agama-auto.iso` is the new modified
ISO and the `profile.json` is the autoinstallation profile copied to
the` /autoinst.json` location in the new ISO.

## Screenshots

When running the autoinstallation manually from the terminal the log is
printed on the console. When running from the systemd service the
logging is redirected to the journal.

The example journal output below contains two service runs, the initial
one with the original client, the second one is started after patching
the client with this pull request. The new log contains more details
(source code locations) and can distinguish between info, warnings and
errors (not shown in this case).

<img width="1280" height="800" alt="agama-autoinst-logging"
src="https://github.com/user-attachments/assets/4ea300d6-3db3-4325-bbc8-c1c7ef1006be"
/>

## Notes

If we want to have a less verbose output on CLI we could modify the
logger to be quiet when the output goes to the terminal and add
`--verbose` option to have it verbose always. But I think it is OK to
have those details by default, it will be useful for debugging later.
2026-04-08 15:58:33 +02:00

16 lines
396 B
TOML

[package]
name = "agama-autoinstall"
version = "0.1.0"
rust-version.workspace = true
edition.workspace = true
[dependencies]
agama-lib = { path = "../agama-lib" }
agama-utils = { path = "../agama-utils" }
agama-transfer = { path = "../agama-transfer" }
anyhow = { version = "1.0.98" }
tempfile = "3.20.0"
tokio = "1.46.0"
tracing = "0.1.44"
url = "2.5.4"
agama-l10n = { path = "../agama-l10n" }