Flake lock file updates: • Updated input 'dream2nix': 'github:nix-community/dream2nix/1b5e01219a32324c8f6889fe1f4db933ec7932f6?narHash=sha256-04gy1icwnGO3ZXF6r96yBm/C0PNPzeLxA/8xzzq0dBI%3D' (2024-06-29) → 'github:nix-community/dream2nix/8ce6284ff58208ed8961681276f82c2f8f978ef4?narHash=sha256-n5CwhmqKxifuD4Sq4WuRP/h5LO6f23cGnSAuJemnd/4%3D' (2024-12-25) • Updated input 'dream2nix/nixpkgs': 'github:NixOS/nixpkgs/1e3deb3d8a86a870d925760db1a5adecc64d329d?narHash=sha256-vN5xJAZ4UGREEglh3lfbbkIj%2BMPEYMuqewMn4atZFaQ%3D' (2024-06-27) → 'github:NixOS/nixpkgs/41dea55321e5a999b17033296ac05fe8a8b5a257?narHash=sha256-WvLXzNNnnw%2BqpFOmgaM3JUlNEH%2BT4s22b5i2oyyCpXE%3D' (2024-10-25) • Updated input 'dream2nix/purescript-overlay': 'github:thomashoneyman/purescript-overlay/047c7933abd6da8aa239904422e22d190ce55ead?narHash=sha256-eMjFmsj2G1E0Q5XiibUNgFjTiSz0GxIeSSzzVdoN730%3D' (2023-09-29) → 'github:thomashoneyman/purescript-overlay/4ad4c15d07bd899d7346b331f377606631eb0ee4?narHash=sha256-Sws7w0tlnjD%2BBjck1nv29NjC5DbL6nH5auL9Ex9Iz2A%3D' (2024-10-10) • Added input 'dream2nix/purescript-overlay/flake-compat': 'github:edolstra/flake-compat/0f9255e01c2351cc7d116c072cb317785dd33b33?narHash=sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U%3D' (2023-10-04) • Updated input 'dream2nix/purescript-overlay/slimlock': 'github:thomashoneyman/slimlock/b5c6cdcaf636ebbebd0a1f32520929394493f1a6?narHash=sha256-Wg0ViDotFWGWqKIQzyYCgayeH8s4U1OZcTiWTQYdAp4%3D' (2023-07-06) → 'github:thomashoneyman/slimlock/cf72723f59e2340d24881fd7bf61cb113b4c407c?narHash=sha256-xzkkMv3neJJJ89zo3o2ojp7nFeaZc2G0fYwNXNJRFlo%3D' (2023-07-07) • Updated input 'fenix': 'github:nix-community/fenix/ebfe2c639111d7e82972a12711206afaeeda2450?narHash=sha256-K2xFp142onP35jcx7li10xUxNVEVRWjAdY8DSuR7Naw%3D' (2024-07-01) → 'github:nix-community/fenix/ac79bb490b8c1af4bbc587b84c76f9527d6b14f7?narHash=sha256-lvp77MhGzSN%2BICd0MugppCjQR6cmlM2iAC5cjy2ZsaA%3D' (2025-01-18) • Updated input 'fenix/rust-analyzer-src': 'github:rust-lang/rust-analyzer/ea7fdada6a0940b239ddbde2048a4d7dac1efe1e?narHash=sha256-fsxAuW6RxKZYjAP3biUC6C4vaYFhDfWv8lp1Tmx3ZCY%3D' (2024-06-30) → 'github:rust-lang/rust-analyzer/f61bfa4d7feb84d07538d361fe77d34a29e3b375?narHash=sha256-m4SN8DeKzsP10EQFS7%2B2zgGfCrMhTfTt1H0QRNesD08%3D' (2025-01-17) • Updated input 'nixpkgs': 'github:nixos/nixpkgs/7dca15289a1c2990efbe4680f0923ce14139b042?narHash=sha256-RoxIr/fbndtuKqulGvNCcuzC6KdAib85Q8gXnjzA1dw%3D' (2024-06-30) → 'github:nixos/nixpkgs/6a3ae7a5a12fb8cac2d59d7df7cbd95f9b2f0566?narHash=sha256-s40Kk/OulP3J/1JvC3VT16U4r/Xw6Qdi7SRw3LYkPWs%3D' (2025-01-18)
81 lines
1.9 KiB
Nix
81 lines
1.9 KiB
Nix
{
|
|
description = "tlater.net web server";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
|
|
dream2nix.url = "github:nix-community/dream2nix";
|
|
|
|
fenix = {
|
|
url = "github:nix-community/fenix";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
};
|
|
|
|
outputs = {
|
|
self,
|
|
nixpkgs,
|
|
dream2nix,
|
|
fenix,
|
|
}: let
|
|
# At the moment, we only deploy to x86_64-linux. Update when we
|
|
# care about another platform.
|
|
system = "x86_64-linux";
|
|
pkgs = nixpkgs.legacyPackages.${system};
|
|
fenixPkgs = fenix.packages.${system};
|
|
ownPkgs = self.packages.${system};
|
|
in {
|
|
packages.${system} = dream2nix.lib.importPackages {
|
|
projectRoot = ./.;
|
|
projectRootFile = "flake.nix";
|
|
packagesDir = ./packages;
|
|
packageSets = {
|
|
nixpkgs = pkgs;
|
|
fenix = fenixPkgs;
|
|
};
|
|
};
|
|
|
|
apps.${system} = {
|
|
default = let
|
|
inherit (ownPkgs) server templates;
|
|
inherit (pkgs) writeShellScript;
|
|
in {
|
|
type = "app";
|
|
program = builtins.toString (writeShellScript "tlaternet-webserver" ''
|
|
${server}/bin/tlaternet-webserver --template-directory ${templates}
|
|
'');
|
|
};
|
|
|
|
update = let
|
|
update-script = pkgs.callPackage ./nix/update.nix {inherit self;};
|
|
in {
|
|
type = "app";
|
|
program = "${update-script}/bin/update";
|
|
};
|
|
};
|
|
|
|
nixosModules.default = import ./nix/module.nix {inherit self system;};
|
|
|
|
devShells.${system} = {
|
|
server = pkgs.mkShell {
|
|
packages = [
|
|
(fenixPkgs.stable.withComponents [
|
|
"rustc"
|
|
"cargo"
|
|
"rustfmt"
|
|
"rust-std"
|
|
"rust-docs"
|
|
"clippy"
|
|
"rust-src"
|
|
"rust-analysis"
|
|
])
|
|
fenixPkgs.rust-analyzer
|
|
];
|
|
};
|
|
};
|
|
|
|
checks.${system} = import ./nix/checks {
|
|
inherit self pkgs;
|
|
};
|
|
};
|
|
}
|