From 8d3c7a8fd543e4b044681513db3463332aa70a30 Mon Sep 17 00:00:00 2001 From: Adrian G L Date: Sun, 16 Jun 2024 18:11:01 +0200 Subject: [PATCH] buskerud: Temporarily added ozai and ozai-webui --- flake.nix | 13 ++++++++++++- hosts/buskerud/configuration.nix | 2 ++ hosts/buskerud/services/ozai.nix | 16 ++++++++++++++++ 3 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 hosts/buskerud/services/ozai.nix diff --git a/flake.nix b/flake.nix index 929c79d..f6d41fb 100644 --- a/flake.nix +++ b/flake.nix @@ -27,6 +27,12 @@ grzegorz.inputs.nixpkgs.follows = "nixpkgs-unstable"; grzegorz-clients.url = "github:Programvareverkstedet/grzegorz-clients"; grzegorz-clients.inputs.nixpkgs.follows = "nixpkgs"; + + ozai.url = "git+https://git.pvv.ntnu.no/Projects/ozai.git"; + ozai.inputs.nixpkgs.follows = "nixpkgs"; + ozai-webui.url = "git+https://git.pvv.ntnu.no/adriangl/ozai-webui.git"; + ozai-webui.inputs.nixpkgs.follows = "nixpkgs"; + }; outputs = { self, nixpkgs, nixpkgs-unstable, pvv-nettsiden, sops-nix, disko, ... }@inputs: @@ -121,7 +127,12 @@ inputs.grzegorz-clients.nixosModules.grzegorz-webui ]; }; - buskerud = stableNixosConfig "buskerud" { }; + buskerud = stableNixosConfig "buskerud" { + modules = [ + ozai.nixosModules.ozai + ozai-webui.nixosModules.ozai-webui + ]; + }; }; devShells = forAllSystems (system: { diff --git a/hosts/buskerud/configuration.nix b/hosts/buskerud/configuration.nix index 14eec65..52ce4b5 100644 --- a/hosts/buskerud/configuration.nix +++ b/hosts/buskerud/configuration.nix @@ -4,6 +4,8 @@ ./hardware-configuration.nix ../../base.nix ../../misc/metrics-exporters.nix + + ./services/ozai.nix ]; # buskerud does not support efi? diff --git a/hosts/buskerud/services/ozai.nix b/hosts/buskerud/services/ozai.nix new file mode 100644 index 0000000..6afb916 --- /dev/null +++ b/hosts/buskerud/services/ozai.nix @@ -0,0 +1,16 @@ +{ config, pkgs, lib, ... }: +{ + + services.ozai = { + enable = true; + host = "0.0.0.0"; + port = 8000; + }; + + services.ozai-webui = { + enable = true; + port = 8080; + host = "0.0.0.0"; + }; + +}