From bc2154400c602eaf8fd3cb9f12328b22e75df186 Mon Sep 17 00:00:00 2001 From: wytch Date: Wed, 15 Apr 2026 11:12:08 -0500 Subject: [PATCH] initial commit --- flake.nix | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 flake.nix diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..7bd60b8 --- /dev/null +++ b/flake.nix @@ -0,0 +1,30 @@ +{ + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-20.03"; + + outputs = { self, nixpkgs }: { + + nixosConfigurations.container = nixpkgs.lib.nixosSystem { + system = "x86_64-linux"; + modules = + [ ({ pkgs, ... }: { + boot.isContainer = true; + + # Let 'nixos-version --json' know about the Git revision + # of this flake. + system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev; + + # Network configuration. + networking.useDHCP = false; + networking.firewall.allowedTCPPorts = [ 80 ]; + + # Enable a web server. + services.httpd = { + enable = true; + adminAddr = "morty@example.org"; + }; + }) + ]; + }; + + }; +}