diff --git a/.gitignore b/.gitignore index 21f979d..f094862 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,2 @@ !**/.keep result -flake.lock diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..8730827 --- /dev/null +++ b/flake.lock @@ -0,0 +1,61 @@ +{ + "nodes": { + "flake-utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1731533236, + "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1754292888, + "narHash": "sha256-1ziydHSiDuSnaiPzCQh1mRFBsM2d2yRX9I+5OPGEmIE=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "ce01daebf8489ba97bd1609d185ea276efdeb121", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-25.05", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "flake-utils": "flake-utils", + "nixpkgs": "nixpkgs" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/nixos/default.nix b/nixos/default.nix index e2637ac..5ce655e 100644 --- a/nixos/default.nix +++ b/nixos/default.nix @@ -4,8 +4,5 @@ pkgs, ... }: { - imports = [ - ./trash - ./services - ]; + imports = []; } diff --git a/nixos/services/default.nix b/nixos/services/default.nix deleted file mode 100644 index 36b456a..0000000 --- a/nixos/services/default.nix +++ /dev/null @@ -1,10 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: { - imports = [ - ./forgejo - ]; -} diff --git a/nixos/services/forgejo/default.nix b/nixos/services/forgejo/default.nix deleted file mode 100644 index b15d2d9..0000000 --- a/nixos/services/forgejo/default.nix +++ /dev/null @@ -1,66 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: -with lib; let - cfg = config.options.trivium.services.forgejo; -in { - options.trivium.services.forgejo = { - enable = mkEnableOption "forgejo settings"; - - virtualHost = mkOption { - type = types.string; - description = "Virtualhost to use for nginx's reverse proxy. Usually something like git..com"; - }; - - appName = mkOption { - type = types.string; - description = "You guess what this does"; - }; - - disableRegistration = mkOption { - type = types.bool; - default = true; - description = "Turn this off just to create the first admin account"; - }; - }; - - config = mkIf cfg.enable { - services = { - nginx = { - virtualHosts."${cfg.virtualHost}" = { - enableACME = true; - forceSSL = true; - locations."/".proxyPass = "http://localhost:9170"; - }; - }; - - forgejo = { - enable = true; - lfs.enable = true; - useWizard = false; - settings = { - general.APP_NAME = "${cfg.appName}"; - ui.DEFAULT_THEME = "forgejo-dark"; - server = { - DOMAIN = "${cfg.virtualHost}"; - ROOT_URL = "https://${cfg.virtualHost}"; - HTTP_PORT = 9170; - LANDING_PAGE = "explore"; - }; - - service.DISABLE_REGISTRATION = ${cfg.disableRegistration}; - - actions = { - ENABLED = true; - }; - mailer = { - ENABLED = false; - }; - }; - }; - }; - }; -} diff --git a/nixos/trash/default.nix b/nixos/trash/default.nix deleted file mode 100644 index a8c8785..0000000 --- a/nixos/trash/default.nix +++ /dev/null @@ -1,10 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: { - imports = [ - ./steam - ]; -} diff --git a/nixos/trash/steam/default.nix b/nixos/trash/steam/default.nix deleted file mode 100644 index 80a45e8..0000000 --- a/nixos/trash/steam/default.nix +++ /dev/null @@ -1,55 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: -with lib; let - cfg = config.options.trivium.trash.steam; -in { - options.trivium.trash.steam = { - enable = mkEnableOption "steam settings"; - - compatibilityPackages = mkOption { - type = types.bool; - default = true; - description = "Enable additional compatibility packages (protontricks, protonup, etc.)"; - }; - - remotePlayOpenFirewall = mkOption { - type = types.bool; - default = false; - description = "Open firewall for Steam Remote Play"; - }; - - dedicatedServerOpenFirewall = mkOption { - type = types.bool; - default = false; - description = "Open firewall for Steam Dedicated Server"; - }; - - localNetworkGameTransfersOpenFirewall = mkOption { - type = types.bool; - default = false; - description = "Open firewall for Steam Local Network Game Transfers"; - }; - }; - - config = mkIf cfg.enable { - programs.steam = { - enable = true; - remotePlay.openFirewall = cfg.remotePlayOpenFirewall; - dedicatedServer.openFirewall = cfg.dedicatedServerOpenFirewall; - localNetworkGameTransfers.openFirewall = cfg.localNetworkGameTransfersOpenFirewall; - }; - - environment = mkIf cfg.compatibilityPackages { - systemPackages = with pkgs; [ - protontricks - protonup - protonup-ng - winetricks - ]; - }; - }; -}