import printerfacts

Signed-off-by: Xe <me@christine.website>
This commit is contained in:
Cadey Ratio 2021-12-26 12:01:31 -05:00
parent fbd5612839
commit 4b530a1cb1
3 changed files with 132 additions and 4 deletions

View File

@ -4,7 +4,14 @@
boot.cleanTmpDir = true; boot.cleanTmpDir = true;
boot.kernelModules = [ "wireguard" ]; boot.kernelModules = [ "wireguard" ];
environment.systemPackages = with pkgs; [ age minisign tmate jq nfs-utils git ]; environment.systemPackages = with pkgs; [
age
minisign
tmate
jq
nfs-utils
git
];
nix = { nix = {
autoOptimiseStore = true; autoOptimiseStore = true;
@ -41,4 +48,21 @@
enable = true; enable = true;
dnssec = "false"; dnssec = "false";
}; };
users.groups.within = { };
systemd.services.within-homedir-setup = {
description = "Creates homedirs for /srv/within services";
wantedBy = [ "multi-user.target" ];
serviceConfig.Type = "oneshot";
script = with pkgs; ''
${coreutils}/bin/mkdir -p /srv/within
${coreutils}/bin/chown root:within /srv/within
${coreutils}/bin/chmod 775 /srv/within
${coreutils}/bin/mkdir -p /srv/within/run
${coreutils}/bin/chown root:within /srv/within/run
${coreutils}/bin/chmod 770 /srv/within/run
'';
};
} }

View File

@ -54,6 +54,21 @@
"type": "github" "type": "github"
} }
}, },
"flake-utils": {
"locked": {
"lastModified": 1638122382,
"narHash": "sha256-sQzZzAbvKEqN9s0bzWuYmRaA03v40gaJ4+iL1LXjaeI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "74f7e4319258e287b0f9cb95426c9853b282730b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs_3" "nixpkgs": "nixpkgs_3"
@ -72,6 +87,24 @@
"type": "github" "type": "github"
} }
}, },
"naersk": {
"inputs": {
"nixpkgs": "nixpkgs_5"
},
"locked": {
"lastModified": 1639947939,
"narHash": "sha256-pGsM8haJadVP80GFq4xhnSpNitYNQpaXk4cnA796Cso=",
"owner": "nix-community",
"repo": "naersk",
"rev": "2fc8ce9d3c025d59fee349c1f80be9785049d653",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "naersk",
"type": "github"
}
},
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1618628710, "lastModified": 1618628710,
@ -131,13 +164,42 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_5": {
"locked": {
"lastModified": 1640418986,
"narHash": "sha256-a8GGtxn2iL3WAkY5H+4E0s3Q7XJt6bTOvos9qqxT5OQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "5c37ad87222cfc1ec36d6cd1364514a9efc2f7f2",
"type": "github"
},
"original": {
"id": "nixpkgs",
"type": "indirect"
}
},
"nixpkgs_6": {
"locked": {
"lastModified": 1640418986,
"narHash": "sha256-a8GGtxn2iL3WAkY5H+4E0s3Q7XJt6bTOvos9qqxT5OQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "5c37ad87222cfc1ec36d6cd1364514a9efc2f7f2",
"type": "github"
},
"original": {
"id": "nixpkgs",
"type": "indirect"
}
},
"root": { "root": {
"inputs": { "inputs": {
"agenix": "agenix", "agenix": "agenix",
"deploy-rs": "deploy-rs", "deploy-rs": "deploy-rs",
"home-manager": "home-manager", "home-manager": "home-manager",
"nixpkgs": "nixpkgs_4", "nixpkgs": "nixpkgs_4",
"utils": "utils_2" "utils": "utils_2",
"xe-printerfacts": "xe-printerfacts"
} }
}, },
"utils": { "utils": {
@ -169,6 +231,44 @@
"repo": "flake-utils", "repo": "flake-utils",
"type": "github" "type": "github"
} }
},
"xe-printerfacts": {
"inputs": {
"flake-utils": "flake-utils",
"naersk": "naersk",
"nixpkgs": "nixpkgs_6",
"xess": "xess"
},
"locked": {
"lastModified": 1640537740,
"narHash": "sha256-lDUP2f67O3QEtZAJ6A7wrzyQJTqPojz7GMId/ae743g=",
"ref": "main",
"rev": "74ee429392f1be09e831f0ec750967b8c4021131",
"revCount": 44,
"type": "git",
"url": "https://tulpa.dev/cadey/printerfacts.git"
},
"original": {
"ref": "main",
"type": "git",
"url": "https://tulpa.dev/cadey/printerfacts.git"
}
},
"xess": {
"flake": false,
"locked": {
"lastModified": 1637634344,
"narHash": "sha256-63zWhmRpppLzh+H70gHSViHfZ4JvtnOFDRrrjkXtzJE=",
"owner": "Xe",
"repo": "Xess",
"rev": "f9ffc529fca9751afdce2408089c51e73d56fce8",
"type": "github"
},
"original": {
"owner": "Xe",
"repo": "Xess",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",

View File

@ -7,17 +7,21 @@
home-manager.url = "github:nix-community/home-manager"; home-manager.url = "github:nix-community/home-manager";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
utils.url = "github:numtide/flake-utils"; utils.url = "github:numtide/flake-utils";
# my apps
xe-printerfacts.url = "git+https://tulpa.dev/cadey/printerfacts.git?ref=main";
}; };
outputs = { self, nixpkgs, deploy-rs, home-manager, agenix, ... }: outputs = { self, nixpkgs, deploy-rs, home-manager, agenix, xe-printerfacts, ... }:
let let
pkgs = nixpkgs.legacyPackages."x86_64-linux"; pkgs = nixpkgs.legacyPackages."x86_64-linux";
mkSystem = extraModules: mkSystem = extraModules:
nixpkgs.lib.nixosSystem { nixpkgs.lib.nixosSystem rec {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
agenix.nixosModules.age agenix.nixosModules.age
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
xe-printerfacts.nixosModules."${system}".printerfacts
({ config, ... }: { ({ config, ... }: {
system.configurationRevision = self.sourceInfo.rev; system.configurationRevision = self.sourceInfo.rev;
services.getty.greetingLine = services.getty.greetingLine =