-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
55 lines (47 loc) · 1.22 KB
/
flake.nix
File metadata and controls
55 lines (47 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
{
description = "A Go full-stack web app with PostgreSQL, HTMX, and Nix flake support";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
in
{
devShell = pkgs.mkShell {
hardeningDisable = [ "fortify" ];
buildInputs = with pkgs; [
go_1_22
gcc
docker
postgresql
migrate
golangci-lint
sqlc
tailwindcss
makeWrapper
cypress
];
shellHook = ''
export PATH=$PWD/bin:$PATH
'';
};
packages.default = pkgs.buildGoModule {
pname = "alice-traint";
version = "0.1.0";
src = ./.;
vendorSha256 = null;
goModVendor = true;
buildPhase = ''
go build -o $out/bin/alice-traint ./cmd/alice-traint
'';
meta = with pkgs.lib; {
description = "A Go full-stack web app";
license = licenses.mit;
maintainers = [ maintainers.mytkom ];
};
};
});
}