Many things:

- updated inputs
- added new host `hs`
- workflows to check and release new host `hs`
- chrome instead of chromium (if not on aarch64)
- fixed bud configuration error for `pc` host
- fixed Emacs purescript format on save
This commit is contained in:
Andrea Ciceri 2021-11-13 19:01:43 +01:00
parent 4e8adcfafb
commit ecb7bc935b
No known key found for this signature in database
GPG key ID: A1FC89532D1C5654
13 changed files with 125 additions and 72 deletions

View file

@ -36,4 +36,5 @@ jobs:
- run: sed -i 's/#\(.*\).*\#.* ga-uncomment/\1/g' flake.nix # disabling outputs unsupported inside the GitHub action
- run: nix -Lv flake check
- run: nix -Lv build ".#nixosConfigurations.pc.config.system.build.toplevel"
- run: nix -Lv build ".#nixosConfigurations.hs.config.system.build.toplevel"
- run: nix -Lv develop -c echo OK

View file

@ -35,6 +35,7 @@ jobs:
name: aciceri-fleet
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- run: nix -Lv develop -c bud build pc bootstrapIso
- run: nix -Lv develop -c bud build hs bootstrapIso
- uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: '${{ secrets.GITHUB_TOKEN }}'

115
flake.lock generated
View file

@ -70,11 +70,11 @@
]
},
"locked": {
"lastModified": 1631730143,
"narHash": "sha256-A8PaUyZu5WVp+IojG5q+39rjf5x57OFDYmVoDFPZLlY=",
"lastModified": 1634994402,
"narHash": "sha256-xmlCVVOYGpZoxgOqsDOVF0B0ASrnbNGVAEzID9qh2xo=",
"owner": "LnL7",
"repo": "nix-darwin",
"rev": "e1a3f7292f085fd588d11f94ed0f47968c16df0c",
"rev": "44da835ac40dab5fd231298b59d83487382d2fab",
"type": "github"
},
"original": {
@ -86,10 +86,9 @@
"deploy": {
"inputs": {
"flake-compat": "flake-compat",
"naersk": "naersk",
"nixpkgs": [
"digga",
"nixpkgs"
"latest"
],
"utils": [
"digga",
@ -97,11 +96,11 @@
]
},
"locked": {
"lastModified": 1628752686,
"narHash": "sha256-Lzh9MYUJDsjgif+YEyOErXtj1IH+ci8J1C30g1ms69s=",
"lastModified": 1632822684,
"narHash": "sha256-lt7eayYmgsD5OQwpb1XYfHpxttn43bWo7G7hIJs+zJw=",
"owner": "serokell",
"repo": "deploy-rs",
"rev": "e5546f9c2503c26d175f08a81fc0a0f330be4cbe",
"rev": "9a02de4373e0ec272d08a417b269a28ac8b961b4",
"type": "github"
},
"original": {
@ -112,11 +111,11 @@
},
"devshell": {
"locked": {
"lastModified": 1629275356,
"narHash": "sha256-R17M69EKXP6q8/mNHaK53ECwjFo1pdF+XaJC9Qq8zjg=",
"lastModified": 1632436039,
"narHash": "sha256-OtITeVWcKXn1SpVEnImpTGH91FycCskGBPqmlxiykv4=",
"owner": "numtide",
"repo": "devshell",
"rev": "26f25a12265f030917358a9632cd600b51af1d97",
"rev": "7a7a7aa0adebe5488e5abaec688fd9ae0f8ea9c6",
"type": "github"
},
"original": {
@ -135,6 +134,7 @@
"home-manager": [
"home"
],
"latest": "latest",
"nix": "nix",
"nixlib": [
"stable"
@ -145,11 +145,11 @@
]
},
"locked": {
"lastModified": 1631974852,
"narHash": "sha256-f2K83yDufQWp22kjtOQXHfsXXyUbndCMxrhG57mI9DE=",
"lastModified": 1634161492,
"narHash": "sha256-7OZz7DqAhO+3axY68xsMXAyD+b5gJgVXuKjslTSCM3Y=",
"owner": "divnix",
"repo": "digga",
"rev": "8e91e1814ef0ab294731ceb106ffdac009363702",
"rev": "a55450a16d362b6e1c50bb4025aaa604b385d3ba",
"type": "github"
},
"original": {
@ -160,11 +160,11 @@
},
"emacs-overlay": {
"locked": {
"lastModified": 1632503972,
"narHash": "sha256-nWVCMFZV5UbzVmdP4CjWlFcmi6YO/ssnS3X/p4oeTuE=",
"lastModified": 1636794537,
"narHash": "sha256-LNnwJte2m6eZZYf2/oC7oEs+3padSuXjgFHkvljvEls=",
"owner": "nix-community",
"repo": "emacs-overlay",
"rev": "b1513bd49d141a1df1f0a7692c896f6178182938",
"rev": "254678418cb80265cbb0e20df9a79b37c2a70ab2",
"type": "github"
},
"original": {
@ -176,11 +176,11 @@
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1606424373,
"narHash": "sha256-oq8d4//CJOrVj+EcOaSXvMebvuTkmBJuT5tzlfewUnQ=",
"lastModified": 1627913399,
"narHash": "sha256-hY8g6H2KFL8ownSiFeMOjwPC8P0ueXpCVEbxgda3pko=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "99f1c2157fba4bfe6211a321fd0ee43199025dbf",
"rev": "12c64ca55c1014cdc1b16ed5a804aa8576601ff2",
"type": "github"
},
"original": {
@ -247,11 +247,11 @@
]
},
"locked": {
"lastModified": 1631573611,
"narHash": "sha256-u2E/wstadWNcn6vOIoK1xY86QPOzzBZQfT1FbePfdaI=",
"lastModified": 1634544068,
"narHash": "sha256-RlRQBaAHfdWqfRyHdWuDPMkplBTYwuyDQqDcNbP/Sog=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "7d9ba15214004c979d2c8733f8be12ce6502cf8a",
"rev": "ff2bed9dac84fb202bbb3c49fdcfe30c29d0b12f",
"type": "github"
},
"original": {
@ -261,6 +261,22 @@
"type": "github"
}
},
"latest": {
"locked": {
"lastModified": 1632660378,
"narHash": "sha256-sjA8eQlnyDjDLyAyq3XlJmN0nqW0ftl/pb7VnMg86L0=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "31ffc50c571e6683e9ecc9dbcbd4a8e9914b4497",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"lowdown-src": {
"flake": false,
"locked": {
@ -278,29 +294,6 @@
"type": "github"
}
},
"naersk": {
"inputs": {
"nixpkgs": [
"digga",
"deploy",
"nixpkgs"
]
},
"locked": {
"lastModified": 1622810282,
"narHash": "sha256-4wmvM3/xfD0hCdNDIXVzRMfL4yB1J+DjH6Zte2xbAxk=",
"owner": "nmattia",
"repo": "naersk",
"rev": "e8061169e1495871b56be97c5c51d310fae01374",
"type": "github"
},
"original": {
"owner": "nmattia",
"ref": "master",
"repo": "naersk",
"type": "github"
}
},
"nix": {
"inputs": {
"lowdown-src": "lowdown-src",
@ -363,11 +356,11 @@
},
"nixos-hardware": {
"locked": {
"lastModified": 1632267580,
"narHash": "sha256-AvNXdmaPHYs6idbfgu1H40vEw4Wq15xLAgCnpCN1l1A=",
"lastModified": 1636317251,
"narHash": "sha256-u1cWvvtGH5mfGkeIKrqw2usk4IL7wDiRcnJkUSiZq3Q=",
"owner": "nixos",
"repo": "nixos-hardware",
"rev": "3cc8c47af31798040ea62499090540413279f832",
"rev": "fd6f34afcf062761fb5035230f6297752bfedcba",
"type": "github"
},
"original": {
@ -386,11 +379,11 @@
]
},
"locked": {
"lastModified": 1634158823,
"narHash": "sha256-l+LXVfmCH+Xk7nzghlEIAkrSta93ANax2MgRgbh6aZg=",
"lastModified": 1636730729,
"narHash": "sha256-pIFHZ6nEQPvdbXsCslFWn7DcbiH1o06j8CKt+Rph1pY=",
"owner": "nix-community",
"repo": "nixpkgs-wayland",
"rev": "80a3b4fb3c2ffd318c653ebaff2253dded674965",
"rev": "4643ca2a6b9099841643a48c55bd78fda93533b5",
"type": "github"
},
"original": {
@ -401,11 +394,11 @@
},
"nur": {
"locked": {
"lastModified": 1632348381,
"narHash": "sha256-4TFmCNyQUCOqOmvObWpADyQcYLvwCP0n4Xm9D480QLE=",
"lastModified": 1636800222,
"narHash": "sha256-rQHVTQnt7HCoO/MKXutFA8ArIkJHgut/96giwryMOpw=",
"owner": "nix-community",
"repo": "NUR",
"rev": "752846b22288b693ee6428ec10dcd0e6cd96bc54",
"rev": "3a6eb10aeb8ed51a307c5867765379a0d82bc3e8",
"type": "github"
},
"original": {
@ -431,11 +424,11 @@
]
},
"locked": {
"lastModified": 1628690139,
"narHash": "sha256-9bk59V0YjZnMfSQMCHuYVPA/Bc3enjTtoyTWt1B3/zE=",
"lastModified": 1634524567,
"narHash": "sha256-v9ZTZj1WNQaaVfs1P1mUPuh518mmwpqszj1EjdeGUmc=",
"owner": "berberman",
"repo": "nvfetcher",
"rev": "e9600782adbf6fb8217087bd2f05335cad96e542",
"rev": "807513f4bbd0e3b5863f4c3b91f8ac846ed6da9b",
"type": "github"
},
"original": {
@ -528,11 +521,11 @@
},
"stable": {
"locked": {
"lastModified": 1634115022,
"narHash": "sha256-K9DZMQ47VRrg9gtTPwex5p0E8LnwM/dDkNe7AQW0qj0=",
"lastModified": 1636792033,
"narHash": "sha256-5RwKd3+OolhWAPUQG9SNoptr9eks8j2oukKgjAo5NQA=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "564cb4d81d4f734dd068684adec5a60077397fe9",
"rev": "68d4f5970b69b0fd0a95c57c8d0ab4b2b68fb9aa",
"type": "github"
},
"original": {

View file

@ -110,8 +110,8 @@
nixos = {
hostDefaults = {
channelName = "unstable";
imports = [ (digga.lib.importModules ./modules) ];
externalModules = [
imports = [ (digga.lib.importExportableModules ./modules) ];
modules = [
{ lib.our = self.lib; }
digga.nixosModules.bootstrapIso
digga.nixosModules.nixConfig
@ -125,6 +125,10 @@
system = "x86_64-linux";
imports = [{ modules = ./hosts/pc; }];
};
hs = {
system = "x86_64-linux";
imports = [{ modules = ./hosts/hs; }];
};
pbp = {
system = "aarch64-linux";
imports = [{ modules = ./hosts/pbp; }];
@ -154,8 +158,8 @@
};
home = {
imports = [ (digga.lib.importModules ./users/modules) ];
externalModules = [ ];
imports = [ (digga.lib.importExportableModules ./users/modules) ];
modules = [ ];
importables = rec {
profiles = digga.lib.rakeLeaves ./users/profiles;
suites = with profiles; rec {

View file

@ -0,0 +1,36 @@
{ config, lib, pkgs, profiles, ... }:
{
imports = with profiles; [ sshd ];
boot = {
initrd.availableKernelModules = [ "ohci_pci" "ehci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" ];
loader.grub = pkgs.lib.mkForce {
enable = true;
version = 2;
device = "/dev/disk/by-label/nixos";
};
};
fileSystems = {
"/" =
{
device = "/dev/disk/by-label/nixos";
fsType = "btrfs";
};
"/mnt/archivio" = {
device = "/dev/disk/by-label/archivio";
fsType = "ext4";
};
"/mnt/film" = {
device = "/dev/disk/by-label/film";
fsType = "ext4";
};
};
swapDevices =
[{ device = "/dev/disk/by-label/swap"; }];
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
}

9
hosts/hs/default.nix Normal file
View file

@ -0,0 +1,9 @@
{ suites, ... }:
{
imports = [
./configuration.nix
] ++ suites.base;
bud.enable = true;
bud.localFlakeClone = "/home/ccr/fleet";
}

View file

@ -5,5 +5,5 @@
] ++ suites.base;
bud.enable = true;
bud.localFlakeClone = "/home/andrea/fleet";
bud.localFlakeClone = "/home/ccr/fleet";
}

View file

@ -46,6 +46,9 @@ in
time.timeZone = "Europe/Rome";
location.provider = "geoclue2";
users.users.root.openssh.authorizedKeys.keys = [ "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDJmn7H6wxrxCHypvY74Z6pBr5G6v564NaUZb9xIILV92JEdpZzuTLLlP+JkMx/8MLRy+pC7prMwR+FhH+LaTm/9x3T6FYP/q9UIAL3cFwBAwj5XQXQKzx9f6pX/7iJrMfAUQ+ZrRUNJHt5Gl+8UypmDgnQLuv5vmQSMRzKnUPuu4lCJtWOpSPhXffz3Ec1tm5nAMuxIMRPY91PYu1fMLlFrjB1FX1goVHKB1uWx16GjJszYCVbN6xcPac0sgUg+qNGBhWkUh0F073rhepQJeWp5FtwIxe2zRsZBxxTy5qxNLmHzBeNDxlOkcy2/Lr+BxVy+mhF/2fJziX80/bWSEA1" ];
nix = {
autoOptimiseStore = true;
gc.automatic = true;

View file

@ -1,5 +1,6 @@
{
services.openssh = {
enable = true;
permitRootLogin = "yes";
};
}

View file

@ -1,6 +1,6 @@
{ self, inputs, ... }:
{
externalModules = with inputs; [
exportedModules = with inputs; [
bud.devshellModules.bud
];
modules = [

View file

@ -1,11 +1,16 @@
{ pkgs, suites, lib, ... }:
{ pkgs, suites, lib, config, ... }:
{
home-manager.users.ccr = { suites, ... }: {
imports = with suites; shell ++ gui ++ browser ++ multimedia ++ emails ++ dev ++ base;
imports = with suites; shell ++ base ++ (if config.networking.hostName != "hs" then
(
gui ++ browser ++ multimedia ++ emails ++ dev
) else [ ]);
home.packages = with pkgs; [
ack
ranger
] ++ (if config.networking.hostName != "hs" then [
imv
calibre
element-desktop
@ -16,7 +21,7 @@
yarn
yarn2nix
texlive.combined.scheme-full
];
] else [ ]);
};
users.users.ccr = {

View file

@ -2,6 +2,6 @@
{
programs.chromium = {
enable = true;
package = pkgs.ungoogled-chromium;
package = with pkgs; if stdenv.hostPlatform.isAarch64 then ungoogled-chromium else google-chrome;
};
}

View file

@ -34,8 +34,8 @@
(error "purs-tidy not found")))
:hook
(before-save . purescript-purs-tidy-format-buffer)
(purescript-mode . (lambda ()
(add-hook 'before-save-hook purescript-purs-tidy-format-buffer nil 'make-it-local)
(psc-ide-mode)
(company-mode)
(flycheck-mode)