!PSmBFWNKoXmlQBzUQf:helsinki-systems.de

Stage 1 systemd

82 Members
systemd in NixOs's stage 1, replacing the current bash tooling https://github.com/NixOS/nixpkgs/projects/5126 Servers

Load older messages


SenderMessageTime
24 Apr 2023
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgit's mostly the network-enabled sytemd package and its dependencies21:44:01
@aktaboot:tchncs.de@aktaboot:tchncs.deno idea why I have tpm2-tss though21:44:26
@aktaboot:tchncs.de@aktaboot:tchncs.dethere isn't even a tpm on this laptop21:44:38
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgtpm stuff is currently included when luks is included at all21:45:08
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgwe should probably make that configurable21:45:21
@aktaboot:tchncs.de@aktaboot:tchncs.deoh 👍21:45:24
@lily:lily.flowers@lily:lily.flowersYeah that's another 3.8M store path21:45:40
@aktaboot:tchncs.de@aktaboot:tchncs.dethe root thing is I probably should have put 1GB on /boot which I usually do nowadays21:46:37
@aktaboot:tchncs.de@aktaboot:tchncs.destorage is cheap21:46:44
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgYea I always do 1G, except when I got a 2T SSD for one of my things and decided "fuck it, 2G ESP" :P21:47:29
@lily:lily.flowers@lily:lily.flowersYeah I have mine at 512 MiB21:47:31
@aktaboot:tchncs.de@aktaboot:tchncs.dethanks for the help :) !21:48:10
@lily:lily.flowers@lily:lily.flowers Also ElvishJerricco did we ever fix initrds getting regenerated with every change in nixpkgs revision due to inclusion of that revision in /etc/initrd-release? 21:48:13
@elvishjerricco:matrix.org@elvishjerricco:matrix.org Nope! I think we should just remove BUILD_ID from initrd-release though to fix it 21:48:36
@lily:lily.flowers@lily:lily.flowersSame21:48:45
@mlyx:matrix.org@mlyx:matrix.orgimage.png
Download image.png
21:53:52
@mlyx:matrix.org@mlyx:matrix.orgHow can I disable crypto stuff21:54:21
@aktaboot:tchncs.de@aktaboot:tchncs.deoverrides I guess21:55:10
@lily:lily.flowers@lily:lily.flowers
In reply to @elvishjerricco:matrix.org
tpm stuff is currently included when luks is included at all
I think it's actually included regardless, since it checks for systemd being built with cryptsetup support at all rather than checking for luks
21:55:18
@lily:lily.flowers@lily:lily.flowers(and systemdStage1 is build with cryptsetup support)21:55:29
@lily:lily.flowers@lily:lily.flowers
In reply to @mlyx:matrix.org
How can I disable crypto stuff
boot.initrd.systemd.package = pkgs.systemdStage1.override { withCryptsetup = false; }; I think should do it
21:56:42
@elvishjerricco:matrix.org@elvishjerricco:matrix.org
In reply to @elvishjerricco:matrix.org

If I build these initrds:

let
  pkgs = import ./. {};
  initrd = module: (pkgs.nixos {
    imports = [module];
    fileSystems."/".device = "dummy";
  }).config.system.build.initialRamdisk;
in {
  simple = initrd {};
  network = initrd {
    boot.initrd.network.enable = true;
    boot.initrd.network.ssh.enable = true;
  };
  systemd-simple = initrd {
    boot.initrd.systemd.enable = true;
  };
  systemd-network = initrd {
    boot.initrd.systemd.enable = true;
    boot.initrd.network.enable = true;
    boot.initrd.network.ssh.enable = true;
  };
}

I get these size:

  • simple: 12M
  • network: 13M
  • systemd-simple: 15M
  • systemd-network: 17M
Lily Foster: Hm but the systemd-simple case in this code does get 2M bigger when I add boot.initrd.luks.devices.foo.device = "/dummy";
22:00:12
@aktaboot:tchncs.de@aktaboot:tchncs.demaybe we should have different override options for fido2 and tpm2 ?22:01:31
@lily:lily.flowers@lily:lily.flowersThat's because systemd-cryptsetup does not get added unless luks has devices22:01:31
@lily:lily.flowers@lily:lily.flowers * That's probably because systemd-cryptsetup does not get added unless luks has devices22:01:35
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgah22:01:38
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgok so we need to make the condition in which tpm stuff is added smarter22:01:50
@elvishjerricco:matrix.org@elvishjerricco:matrix.org holy cow if I set boot.initrd.systemd.package = pkgs.systemdStage1 { withCryptsetup = false; }, it goes from 15M to 8.9M 22:02:18
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgwhich is way smaller than the dumbest scripted initrd we can generate22:02:50
@lily:lily.flowers@lily:lily.flowers Should we add another pkgs.systemdStage1Cryptsetup or do something from the module's side? 22:04:02

Show newer messages


Back to Room ListRoom Version: 6