Tweak journald (fix #1)

This commit is contained in:
Roey Darwish Dror 2018-11-04 17:04:22 +02:00
parent 9771446d36
commit a76b6aff0c

View File

@ -32,6 +32,12 @@ BINARIES=()
FILES=()
HOOKS=(base udev block filesystems keyboard fsck)";
static JOURNALD_CONF: &'static str = "
[Journal]
Storage=volatile
SystemMaxUse=16M
";
#[derive(StructOpt)]
#[structopt(name = "alma", about = "Arch Linux Mobile Appliance")]
enum App {
@ -154,6 +160,12 @@ fn create(disk: PathBuf, extra_packages: Vec<String>) -> Result<(), Error> {
.args(&["systemctl", "enable", "NetworkManager"])
.run(ErrorKind::PostInstallation)?;
info!("Configuring journald");
fs::write(
mount_point.path().join("etc/systemd/journald.conf"),
JOURNALD_CONF,
).context(ErrorKind::PostInstallation)?;
info!("Generating initramfs");
fs::write(mount_point.path().join("etc/mkinitcpio.conf"), MKINITCPIO)
.context(ErrorKind::Initramfs)?;