use system.autoUpgrade for nixos machines

also add garnix.io cache

Closes #18
This commit is contained in:
James Walker 2023-12-15 22:28:14 -05:00
parent f85ef16b42
commit ef401a4e4c
Signed by: walkah
SSH Key Fingerprint: SHA256:f7Gn4jO4BFHZxWfKTTzEAfWz+cLW51IyGFl9MjDyZGI
6 changed files with 61 additions and 35 deletions

View File

@ -30,11 +30,11 @@
"utils": "utils" "utils": "utils"
}, },
"locked": { "locked": {
"lastModified": 1702378423, "lastModified": 1702460489,
"narHash": "sha256-tuJ8NWjaH/OuZSZukS6T+suia7E1QIPXW2nzkuUCCNA=", "narHash": "sha256-H6s6oVLvx7PCjUcvfkB89Bb+kbaiJxTAgWfMjiQTjA0=",
"owner": "serokell", "owner": "serokell",
"repo": "deploy-rs", "repo": "deploy-rs",
"rev": "2ccd5d9939d41ac797c3ce769a689fdbc76fdebb", "rev": "915327515f5fd1b7719c06e2f1eb304ee0bdd803",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -75,11 +75,11 @@
"flake-compat": { "flake-compat": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1668681692, "lastModified": 1696426674,
"narHash": "sha256-Ht91NGdewz8IQLtWZ9LCeNXMSXHUss+9COoqu6JLmXU=", "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra", "owner": "edolstra",
"repo": "flake-compat", "repo": "flake-compat",
"rev": "009399224d5e398d03b22badca40a37ac85412a1", "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -138,7 +138,7 @@
}, },
"flake-utils": { "flake-utils": {
"inputs": { "inputs": {
"systems": "systems" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1701680307, "lastModified": 1701680307,
@ -156,7 +156,7 @@
}, },
"flake-utils_2": { "flake-utils_2": {
"inputs": { "inputs": {
"systems": "systems_2" "systems": "systems_3"
}, },
"locked": { "locked": {
"lastModified": 1685518550, "lastModified": 1685518550,
@ -174,7 +174,7 @@
}, },
"flake-utils_3": { "flake-utils_3": {
"inputs": { "inputs": {
"systems": "systems_3" "systems": "systems_4"
}, },
"locked": { "locked": {
"lastModified": 1694529238, "lastModified": 1694529238,
@ -216,11 +216,11 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1702423270, "lastModified": 1702681677,
"narHash": "sha256-3ZA5E+b2XBP+c9qGhWpRApzPq/PZtIPgkeEDpTBV4g8=", "narHash": "sha256-Wa86ehEzoPXb9t1zXfDuKZ4ELQrFicnuuQjgFUCmxLk=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "d9297efd3a1c3ebb9027dc68f9da0ac002ae94db", "rev": "abdc82d930521448e47574b8ca1a0a450e861cca",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -267,11 +267,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1702336390, "lastModified": 1702453208,
"narHash": "sha256-BRO8J8QbmyuS0XMh4UfY11akgTGZj1YhkqNvR83JrsI=", "narHash": "sha256-0wRi9SposfE2wHqjuKt8WO2izKB/ASDOV91URunIqgo=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "fef05bf9c8e818f4ca1425ef4c18e6680becd072", "rev": "7763c6fd1f299cb9361ff2abf755ed9619ef01d6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -283,11 +283,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1701718080, "lastModified": 1702312524,
"narHash": "sha256-6ovz0pG76dE0P170pmmZex1wWcQoeiomUZGggfH9XPs=", "narHash": "sha256-gkZJRDBUCpTPBvQk25G0B7vfbpEYM5s5OZqghkjZsnE=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "2c7f3c0fb7c08a0814627611d9d7d45ab6d75335", "rev": "a9bf124c46ef298113270b1f84a164865987a91c",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -331,11 +331,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1702272962, "lastModified": 1702539185,
"narHash": "sha256-D+zHwkwPc6oYQ4G3A1HuadopqRwUY/JkMwHz1YF7j4Q=", "narHash": "sha256-KnIRG5NMdLIpEkZTnN5zovNYc0hhXjAgv6pfd5Z4c7U=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "e97b3e4186bcadf0ef1b6be22b8558eab1cdeb5d", "rev": "aa9d4729cbc99dabacb50e3994dcefb3ea0f7447",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -356,11 +356,11 @@
"nixpkgs-stable": "nixpkgs-stable" "nixpkgs-stable": "nixpkgs-stable"
}, },
"locked": { "locked": {
"lastModified": 1702325376, "lastModified": 1702456155,
"narHash": "sha256-biLGx2LzU2+/qPwq+kWwVBgXs3MVYT1gPa0fCwpLplU=", "narHash": "sha256-I2XhXGAecdGlqi6hPWYT83AQtMgL+aa3ulA85RAEgOk=",
"owner": "cachix", "owner": "cachix",
"repo": "pre-commit-hooks.nix", "repo": "pre-commit-hooks.nix",
"rev": "e1d203c2fa7e2593c777e490213958ef81f71977", "rev": "007a45d064c1c32d04e1b8a0de5ef00984c419bc",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -451,13 +451,31 @@
"type": "github" "type": "github"
} }
}, },
"utils": { "systems_4": {
"locked": { "locked": {
"lastModified": 1667395993, "lastModified": 1681028828,
"narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=", "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1701680307,
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
"owner": "numtide", "owner": "numtide",
"repo": "flake-utils", "repo": "flake-utils",
"rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f", "rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@ -5,8 +5,8 @@
# Include the results of the hardware scan. # Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
nixos-hardware.nixosModules.raspberry-pi-4 nixos-hardware.nixosModules.raspberry-pi-4
../../modules/base/nixos.nix
../../modules/base
../../modules/ipfs/cluster.nix ../../modules/ipfs/cluster.nix
../../modules/sops ../../modules/sops
]; ];

View File

@ -8,8 +8,8 @@ in
# Include the results of the hardware scan. # Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
../../users ../../users
../../modules/base/nixos.nix
../../modules/base
../../modules/coredns ../../modules/coredns
../../modules/drone ../../modules/drone
../../modules/drone/runner-docker.nix ../../modules/drone/runner-docker.nix
@ -57,7 +57,6 @@ in
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIC5spf4diguK+w7iYLFr565++6DjHukWfvpN2ru9dCRk nixbuild" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIC5spf4diguK+w7iYLFr565++6DjHukWfvpN2ru9dCRk nixbuild"
]; ];
system.autoUpgrade.enable = false;
environment.systemPackages = with pkgs; [ cifs-utils pinentry weechat ]; environment.systemPackages = with pkgs; [ cifs-utils pinentry weechat ];
fileSystems = { fileSystems = {
"/mnt/downloads" = { "/mnt/downloads" = {

View File

@ -3,7 +3,7 @@
./hardware-configuration.nix ./hardware-configuration.nix
./networking.nix # generated at runtime by nixos-infect ./networking.nix # generated at runtime by nixos-infect
../../users ../../users
../../modules/base ../../modules/base/nixos.nix
../../modules/akkoma ../../modules/akkoma
../../modules/akkoma/nginx.nix ../../modules/akkoma/nginx.nix
@ -47,7 +47,6 @@
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ0mE4MyMnfd1b2nlBJT7kpZ6Vov+ILuGNfzdp5ZBNQe walkah@walkah.net" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ0mE4MyMnfd1b2nlBJT7kpZ6Vov+ILuGNfzdp5ZBNQe walkah@walkah.net"
]; ];
system.autoUpgrade.enable = false;
environment.systemPackages = with pkgs; [ ipfs-migrator ]; environment.systemPackages = with pkgs; [ ipfs-migrator ];
walkah.coredns = { walkah.coredns = {

View File

@ -20,10 +20,12 @@
settings = { settings = {
substituters = [ substituters = [
"https://walkah.cachix.org" "https://walkah.cachix.org"
"https://cache.garnix.io"
]; ];
trusted-public-keys = [ trusted-public-keys = [
"walkah.cachix.org-1:D8cO78JoJC6UPV1ZMgd1V5znpk3jNUERGIeAKN15hxo=" "walkah.cachix.org-1:D8cO78JoJC6UPV1ZMgd1V5znpk3jNUERGIeAKN15hxo="
"cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g="
]; ];
}; };
}; };

View File

@ -1,4 +1,4 @@
_: { { config, ... }: {
imports = [ ./common.nix ]; imports = [ ./common.nix ];
@ -20,5 +20,13 @@ _: {
mosh.enable = true; mosh.enable = true;
}; };
system.stateVersion = "23.05"; system = {
autoUpgrade = {
enable = true;
flake = "github:walkah/athens#${config.networking.hostName}";
dates = "daily";
randomizedDelaySec = "5m";
};
stateVersion = "23.05";
};
} }