1
0
Fork 0

Fix auto-update scripts

This commit is contained in:
Aires 2024-05-30 12:19:07 -04:00
parent 1580586883
commit 9342ab263a
2 changed files with 23 additions and 4 deletions

View file

@ -120,6 +120,15 @@ in
Type = "oneshot";
User = config.users.users.aires.name;
};
path = with pkgs; [
coreutils
gnutar
xz.bin
gzip
git
config.nix.package.out
openssh
];
script = ''
set -eu
cd ${config.users.users.aires.home}/Development/nix-configuration

View file

@ -32,11 +32,21 @@
Type = "oneshot";
User = "root";
};
path = with pkgs; [
coreutils
gnutar
xz.bin
gzip
git
config.nix.package.out
nh
openssh
];
script = ''
set -eu
cd ${config.users.users.aires.home}/Development/nix-configuration
sudo -u aires git pull --recurse-submodules
nh os switch
set -eu
cd ${config.users.users.aires.home}/Development/nix-configuration
sudo -u aires git pull --recurse-submodules
nh os switch
'';
};
systemd.timers."nixos-update-timer" = {