Compare commits
11 Commits
8b4d3e1a13
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| aa2b4bbc2e | |||
|
|
865030f5c1 | ||
| f695652bab | |||
|
|
8b4b5897df | ||
| 56b9f7b8d9 | |||
|
|
5f659e19bb | ||
| 8ed749e5f7 | |||
|
|
ff4217466d | ||
|
|
0e45834e45 | ||
| 85d5009104 | |||
|
|
88e7196148 |
42
flake.lock
generated
42
flake.lock
generated
@@ -45,11 +45,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1779036909,
|
"lastModified": 1781242433,
|
||||||
"narHash": "sha256-zXcwYQGCT6pzinK+1dBB2ekTVtfxGZAapb3Evdcu4fY=",
|
"narHash": "sha256-bchLZZ3sRn740zyvD2icZSnNoTaanN0nw7l6fjVXO+E=",
|
||||||
"owner": "lnl7",
|
"owner": "lnl7",
|
||||||
"repo": "nix-darwin",
|
"repo": "nix-darwin",
|
||||||
"rev": "56c666e108467d87d13508936aade6d567f2a501",
|
"rev": "aabb2037edfc0f210723b72cd5f528aab5dd3f0b",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -106,11 +106,11 @@
|
|||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1780065812,
|
"lastModified": 1781168557,
|
||||||
"narHash": "sha256-SCSLUKBmwlSLGQ8Xbr8PjRFtiHNk0l9ktqkcmqdBkfE=",
|
"narHash": "sha256-LOnLQ2tpYF9gqIDDr3+j3DbpJJr/QCH6zPRT2GzEUOE=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixos-hardware",
|
"repo": "nixos-hardware",
|
||||||
"rev": "b76b5639c0593e0aeb0b5879ad62d4b30596c144",
|
"rev": "6358ff76821101c178e3ab4919a62799bfe3652e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -177,11 +177,11 @@
|
|||||||
},
|
},
|
||||||
"nixUnstable": {
|
"nixUnstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1779877693,
|
"lastModified": 1781328464,
|
||||||
"narHash": "sha256-NOF9NAREhxr50bbBfVcVOq+ArCMSoe8dP79Pk2uyARk=",
|
"narHash": "sha256-j9uBlHI0eJ9zWU9IlF6SlBBPdeJu30hcvar31IRKHpw=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "4100e830e085863741bc69b156ec4ccd53ab5be0",
|
"rev": "5a722a7155bfc9fbe657f28d26b71860d95324bc",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -221,11 +221,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1779796641,
|
"lastModified": 1780952837,
|
||||||
"narHash": "sha256-ZsIrKmhp4vbBXoXXmR/tBXA/UCsAQiJL9vsgZEduhVY=",
|
"narHash": "sha256-Fwd1+spDtQ0hDyBwme6ufG3n4mY0UrjjFdYHv+G/Hds=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "25f538306313eae3927264466c70d7001dcea1df",
|
"rev": "e820eb4a444b46a19b2e03e8dfd2359439ff30fe",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -237,11 +237,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_3": {
|
"nixpkgs_3": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1779560665,
|
"lastModified": 1781074563,
|
||||||
"narHash": "sha256-tpyBcxPpcQb8ukyNF7DoCwfSY3VPsxHoYwj00Cayv5o=",
|
"narHash": "sha256-md8WlXOlfnIeHeOScMTTHFyf2d6iaTwPl2apR5EQ3P4=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "64c08a7ca051951c8eae34e3e3cb1e202fe36786",
|
"rev": "9ae611a455b90cf061d8f332b977e387bda8e1ca",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -257,11 +257,11 @@
|
|||||||
"nixpkgs": "nixpkgs_3"
|
"nixpkgs": "nixpkgs_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1780105788,
|
"lastModified": 1781400420,
|
||||||
"narHash": "sha256-Q2WXG6BT1SJ1Iq5SGMqkmbn8tfjJgwCb4zeHccm2Ov0=",
|
"narHash": "sha256-HDTf2EhvFB5TRl+DP4hEMbvVvcQ6ZNMgM9XzBK1PVyA=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "nur",
|
"repo": "nur",
|
||||||
"rev": "47d16fdd3319de3be84372b84ea83d97bd64e1c1",
|
"rev": "1a49876ef73f9aa1c7b88cc6fdbfc81e582ae72a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -290,11 +290,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1777944972,
|
"lastModified": 1780547341,
|
||||||
"narHash": "sha256-VfGRo1qTBKOe3s2gOv8LSoA6Fk19PvBlwQ1ECN0Evn8=",
|
"narHash": "sha256-Gq8KNx5A7hBB3uGJaj6eQfLDIz5YdLu92gqBcvHvoUo=",
|
||||||
"owner": "Mic92",
|
"owner": "Mic92",
|
||||||
"repo": "sops-nix",
|
"repo": "sops-nix",
|
||||||
"rev": "c591bf665727040c6cc5cb409079acb22dcce33c",
|
"rev": "9ed65852b6257fbeae4355bc24ecfea307ca759a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|||||||
@@ -3,8 +3,11 @@ let
|
|||||||
cfg = config.syscfg.server.containers;
|
cfg = config.syscfg.server.containers;
|
||||||
enabledConfigs = lib.filterAttrs (name: c: c.enable) cfg;
|
enabledConfigs = lib.filterAttrs (name: c: c.enable) cfg;
|
||||||
containerSetsList = lib.mapAttrsToList (name: containerCfg:
|
containerSetsList = lib.mapAttrsToList (name: containerCfg:
|
||||||
import (./defs + "/${name}.nix") {
|
let defs = import (./defs + "/${name}.nix") {inherit config pkgs lib containerCfg;};
|
||||||
inherit config pkgs lib containerCfg;
|
in{
|
||||||
|
containers = lib.mapAttrs' (cName: cValue:
|
||||||
|
lib.nameValuePair "${name}-${cName}" cValue
|
||||||
|
) defs.containers;
|
||||||
}
|
}
|
||||||
) enabledConfigs;
|
) enabledConfigs;
|
||||||
mergedContainers = lib.attrsets.mergeAttrsList (lib.map(e: e.containers) containerSetsList);
|
mergedContainers = lib.attrsets.mergeAttrsList (lib.map(e: e.containers) containerSetsList);
|
||||||
|
|||||||
@@ -14,9 +14,8 @@ in {
|
|||||||
|
|
||||||
containers = {
|
containers = {
|
||||||
|
|
||||||
auth_server = {
|
server = {
|
||||||
image = "ghcr.io/goauthentik/server:latest";
|
image = "ghcr.io/goauthentik/server:latest";
|
||||||
hostname = "auth_server";
|
|
||||||
volumes = [
|
volumes = [
|
||||||
"${serverCfg.dataPath}/authentik/media:/media"
|
"${serverCfg.dataPath}/authentik/media:/media"
|
||||||
"${serverCfg.dataPath}/authentik/templates:/templates"
|
"${serverCfg.dataPath}/authentik/templates:/templates"
|
||||||
@@ -47,8 +46,6 @@ in {
|
|||||||
cmd = [ "server" ];
|
cmd = [ "server" ];
|
||||||
extraOptions = [
|
extraOptions = [
|
||||||
"--add-host=host.containers.internal:host-gateway"
|
"--add-host=host.containers.internal:host-gateway"
|
||||||
"--replace"
|
|
||||||
"--rm"
|
|
||||||
"--ip=${containerCfg.ip}"
|
"--ip=${containerCfg.ip}"
|
||||||
];
|
];
|
||||||
ports = [
|
ports = [
|
||||||
@@ -56,9 +53,8 @@ in {
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
auth_worker = {
|
worker = {
|
||||||
image = "ghcr.io/goauthentik/server:latest";
|
image = "ghcr.io/goauthentik/server:latest";
|
||||||
hostname = "auth_worker";
|
|
||||||
volumes = [
|
volumes = [
|
||||||
"${serverCfg.dataPath}/authentik/media:/media"
|
"${serverCfg.dataPath}/authentik/media:/media"
|
||||||
"${serverCfg.dataPath}/authentik/templates:/templates"
|
"${serverCfg.dataPath}/authentik/templates:/templates"
|
||||||
@@ -75,8 +71,6 @@ in {
|
|||||||
};
|
};
|
||||||
extraOptions = [
|
extraOptions = [
|
||||||
"--add-host=host.containers.internal:host-gateway"
|
"--add-host=host.containers.internal:host-gateway"
|
||||||
"--replace"
|
|
||||||
"--rm"
|
|
||||||
];
|
];
|
||||||
cmd = [ "worker" ];
|
cmd = [ "worker" ];
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user