Merge branch 'main' of github.com:asosnovsky/nixos-setup
This commit is contained in:
commit
47638d5f8b
4 files changed
+18
-42
No files matched your search
@@ -43,10 +43,14 @@
|
|||||||
};
|
};
|
||||||
homeManagerVersion = "24.05";
|
homeManagerVersion = "24.05";
|
||||||
# Local Services
|
# Local Services
|
||||||
localNixCaches = [
|
localNixCaches = {
|
||||||
"http://minipc1.lab.internal:5000"
|
urls = [
|
||||||
"http://fwlaptop.devices.internal:5000"
|
"http://minipc1.lab.internal:5000"
|
||||||
];
|
];
|
||||||
|
keys = [
|
||||||
|
"minipc1.lab.internal:eIoib1JgcBEd0YKdW95QlRA2eCKDs+WxNhWhkA1wffc="
|
||||||
|
];
|
||||||
|
};
|
||||||
localDockerRegistries = [ "minipc1.lab.internal:5001" ];
|
localDockerRegistries = [ "minipc1.lab.internal:5001" ];
|
||||||
# Libs
|
# Libs
|
||||||
lib = (import modules/lib.nix {
|
lib = (import modules/lib.nix {
|
||||||
|
|||||||
+5
-33
@@ -1,6 +1,11 @@
|
|||||||
{ user }:
|
{ user }:
|
||||||
{ pkgs, lib, config, ... }: {
|
{ pkgs, lib, config, ... }: {
|
||||||
imports = [ ./hl-minipc1.hardware-configuration.nix ];
|
imports = [ ./hl-minipc1.hardware-configuration.nix ];
|
||||||
|
# Nix Stores
|
||||||
|
services.nix-serve = {
|
||||||
|
enable = true;
|
||||||
|
secretKeyFile = "/var/keys/cache-priv-key.pem";
|
||||||
|
};
|
||||||
# firmware updater
|
# firmware updater
|
||||||
services.fwupd.enable = true;
|
services.fwupd.enable = true;
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
@@ -29,38 +34,5 @@
|
|||||||
listenAddress = "0.0.0.0";
|
listenAddress = "0.0.0.0";
|
||||||
enableDelete = true;
|
enableDelete = true;
|
||||||
};
|
};
|
||||||
virtualisation.oci-containers = {
|
|
||||||
backend = "docker";
|
|
||||||
containers = {
|
|
||||||
myevents-app = {
|
|
||||||
autoStart = true;
|
|
||||||
image = "localhost:5001/asosnovsky/myevents";
|
|
||||||
extraOptions = [ "--gpus" "all" ];
|
|
||||||
ports = [ "8000:80" ];
|
|
||||||
cmd = [ "app" ];
|
|
||||||
environmentFiles = [
|
|
||||||
"/mnt/Data/myevents/app.env"
|
|
||||||
];
|
|
||||||
dependsOn = [ "myevents-db" ];
|
|
||||||
};
|
|
||||||
myevents-cron = {
|
|
||||||
autoStart = true;
|
|
||||||
image = "localhost:5001/asosnovsky/myevents";
|
|
||||||
cmd = [ "cron" ];
|
|
||||||
environmentFiles = [
|
|
||||||
"/mnt/Data/myevents/app.env"
|
|
||||||
];
|
|
||||||
dependsOn = [ "myevents-db" ];
|
|
||||||
};
|
|
||||||
myevents-db = {
|
|
||||||
autoStart = true;
|
|
||||||
image = "docker.io/postgres";
|
|
||||||
hostname = "myevents-db";
|
|
||||||
environmentFiles = [
|
|
||||||
"/mnt/Data/myevents/db.env"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
+1
-1
@@ -17,7 +17,7 @@
|
|||||||
enable = false;
|
enable = false;
|
||||||
enableDevelopmentKit = false;
|
enableDevelopmentKit = false;
|
||||||
}
|
}
|
||||||
, localNixCaches ? [ ]
|
, localNixCaches ? { keys = [ ]; urls = [ ]; }
|
||||||
, ...
|
, ...
|
||||||
}:
|
}:
|
||||||
{ ... }: {
|
{ ... }: {
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{ user, systemStateVersion, localNixCaches ? [ ] }:
|
{ user, systemStateVersion, localNixCaches ? { keys = [ ]; urls = [ ]; } }:
|
||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
# Nix core
|
# Nix core
|
||||||
@@ -10,16 +10,16 @@
|
|||||||
"https://cache.nixos.org"
|
"https://cache.nixos.org"
|
||||||
"https://cache.flox.dev"
|
"https://cache.flox.dev"
|
||||||
"https://devenv.cachix.org"
|
"https://devenv.cachix.org"
|
||||||
] ++ localNixCaches;
|
] ++ localNixCaches.urls;
|
||||||
trusted-substituters = [
|
trusted-substituters = [
|
||||||
"https://cache.flox.dev"
|
"https://cache.flox.dev"
|
||||||
"https://devenv.cachix.org"
|
"https://devenv.cachix.org"
|
||||||
] ++ localNixCaches;
|
] ++ localNixCaches.urls;
|
||||||
trusted-users = [ "root" user.name ];
|
trusted-users = [ "root" user.name ];
|
||||||
trusted-public-keys = [
|
trusted-public-keys = [
|
||||||
"flox-cache-public-1:7F4OyH7ZCnFhcze3fJdfyXYLQw/aV7GEed86nQ7IsOs="
|
"flox-cache-public-1:7F4OyH7ZCnFhcze3fJdfyXYLQw/aV7GEed86nQ7IsOs="
|
||||||
"devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw="
|
"devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw="
|
||||||
];
|
] ++ localNixCaches.keys;
|
||||||
};
|
};
|
||||||
|
|
||||||
# System Packages
|
# System Packages
|
||||||
|
|||||||
Reference in new issue
Block a user