Try fixing zeus
All checks were successful
Nix build / nix-build (nixosConfigurations.apollo.config.system.build.toplevel) (push) Successful in 1m25s
Nix build / nix-build (nixosConfigurations.athene.config.system.build.toplevel) (push) Successful in 57s
Nix build / nix-build (nixosConfigurations.hephaistos.config.system.build.toplevel) (push) Successful in 1m13s
Nix build / nix-build (nixosConfigurations.hera.config.system.build.toplevel) (push) Successful in 54s
Nix build / nix-build (nixosConfigurations.zeus.config.system.build.toplevel) (push) Successful in 2m16s
Nix build / nix-flake-check (push) Successful in 1m37s

This commit is contained in:
maralorn 2024-02-17 20:29:10 +01:00
parent 189b9c603e
commit 63a5a7a12e
2 changed files with 21 additions and 14 deletions

View file

@ -405,11 +405,11 @@
"nixpkgs": []
},
"locked": {
"lastModified": 1707998635,
"narHash": "sha256-3wbu2NvRxMsct6RzkAofaiHSrEoI7H6Vosbai36vfas=",
"lastModified": 1708197897,
"narHash": "sha256-wwFtieLlwmYCTg01BZnoXsiARxFvHmkQhe2gS10HBwA=",
"ref": "refs/heads/main",
"rev": "7cafb0220738b7cfdf961f1b6ae109c33fa268ae",
"revCount": 301,
"rev": "4c0ab6b93c9aa11fe079916df6d33494bc042c17",
"revCount": 303,
"type": "git",
"url": "ssh://gitea@code.maralorn.de/maralorn/config-secrets"
},

View file

@ -1,15 +1,22 @@
{ pkgs, ... }:
let
script = pkgs.writers.writeHaskell "rollback" {
libraries = builtins.attrValues pkgs.myHaskellScriptPackages;
} (builtins.readFile ./sysroot-rollback.hs);
in
{
boot.initrd.systemd.services.rollback = {
description = "Delete everything but /nix and /disk on the root filesystem to get a fresh nixos install.";
wantedBy = [ "initrd-root-fs.target" ];
after = [ "sysroot.mount" ];
unitConfig.DefaultDependencies = "no";
serviceConfig = {
Type = "oneshot";
ExecStart = pkgs.writers.writeHaskell "rollback" {
libraries = builtins.attrValues pkgs.myHaskellScriptPackages;
} (builtins.readFile ./sysroot-rollback.hs);
boot.initrd.systemd = {
storePaths = [ script ];
services.rollback = {
description = "Delete everything but /nix and /disk on the root filesystem to get a fresh nixos install.";
wantedBy = [ "initrd-root-fs.target" ];
after = [ "sysroot.mount" ];
unitConfig.DefaultDependencies = "no";
serviceConfig = {
Type = "oneshot";
ExecStart = script;
};
};
};
}