summaryrefslogtreecommitdiff
path: root/flake.nix
diff options
context:
space:
mode:
authorstuebinm2022-01-17 00:19:59 +0100
committerstuebinm2022-01-20 13:16:43 +0100
commit71a9f3858e42856ef81ad92553a7732811186733 (patch)
treec2fa2ba37bda94491a36fd2e0dffd37d443f7ccb /flake.nix
parentc48f90064724ce1d802038524f60cce7baf53e69 (diff)
attempting home-manager config with flakes
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix58
1 files changed, 37 insertions, 21 deletions
diff --git a/flake.nix b/flake.nix
index 2252d14..aefc703 100644
--- a/flake.nix
+++ b/flake.nix
@@ -1,22 +1,13 @@
-
{
description = "testing nix flakes for server deployment";
inputs = {
- nixpkgs.url = "github:NixOS/nixpkgs/release-21.11";
+ nixpkgs.url = "github:NixOS/nixpkgs/backport-154729-to-release-21.11";
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
uplcg = {
url = "git+https://stuebinm.eu/git/uplcg?ref=main";
flake = false;
};
- # woitb = {
- # url = "git+https://stuebinm.eu/git/woitb?ref=main";
- # flake = false;
- # };
- # workadventure = {
- # url = "git+https://stuebinm.eu/git/workadventure-nix";
- # flake = false;
- # };
tracktrain = {
url = "git+https://stuebinm.eu/git/tracktrain?ref=main";
flake = false;
@@ -25,24 +16,49 @@
url = "path:/home/stuebinm/Dokumente/blog";
flake = false;
};
+ home-manager = {
+ url = "github:nix-community/home-manager/release-21.11";
+ inputs.nixpkgs.follows = "nixpkgs";
+ };
+ playground.url = "git+https://stuebinm.eu/git/playground";
+ playground.flake = false;
+ naersk.url = "github:nix-community/naersk";
+ sfz.url = "github:weihanglo/sfz";
+ sfz.flake = false;
+ feeds.url = "path:/home/stuebinm/newsboat-feeds-private.nix";
+ feeds.flake = false;
};
- outputs = { self, nixpkgs, ... }@inputs: {
+ outputs = { self, nixpkgs, ... }@inputs:
+ let
+ mkConfig = imports: config:
+ nixpkgs.lib.nixosSystem {
+ system = "x86_64-linux";
+ modules = [ config ] ++ imports;
- nixosConfigurations =
- let mkConfig = imports: config: nixpkgs.lib.nixosSystem {
- system = "x86_64-linux";
- modules = [ config ] ++ imports;
+ specialArgs = { inherit inputs; };
+ };
+ mkServer = mkConfig [ ./common/headless.nix ];
+ mkDesktop = mkConfig [ ./common/desktop.nix ];
+ in {
- specialArgs = { inherit inputs; };
- };
- mkServer = mkConfig [ ./common/headless.nix ];
- mkDesktop = mkConfig [ ./common/desktop.nix ];
- in {
+ nixosConfigurations = {
chaski = mkServer ./hosts/chaski/configuration.nix;
flora = mkServer ./hosts/flora/configuration.nix;
abbenay = mkDesktop ./hosts/abbenay/configuration.nix;
cyberbox = mkDesktop ./hosts/cyberbox/configuration.nix;
};
- };
+
+ homeConfigurations.stuebinm =
+ inputs.home-manager.lib.homeManagerConfiguration rec {
+ system = "x86_64-linux";
+ homeDirectory = "/home/stuebinm";
+ username = "stuebinm";
+ configuration.imports = [ ./home/home.nix ];
+ stateVersion = "21.03";
+ extraSpecialArgs = { inherit inputs system; };
+ };
+
+ home = self.homeConfigurations.stuebinm.activationPackage;
+ };
}