all repos — homestead @ 16b0de383b2ad695e8e7c8743ce4624ef305aa44

Code for my website

move server code to cmd/server

Alan Pearce
commit

16b0de383b2ad695e8e7c8743ce4624ef305aa44

parent

5a63e53323a84c4fe654060426fd4e803bde6903

3 files changed, 6 insertions(+), 6 deletions(-)

jump to
M nix/default.nixnix/default.nix
@@ -14,7 +14,7 @@ (pkgs.writeTextDir "config.toml" (builtins.readFile ./../config.toml))
public ]; config = { - Cmd = [ "${server}/bin/website" ]; + Cmd = [ "${server}/bin/server" ]; Env = [ "PRODUCTION=true" "LISTEN_ADDRESS=::"
@@ -39,7 +39,7 @@ root = ./..;
fileset = unions [ ./../go.mod ./../go.sum - ./../cmd + ./../cmd/build ./../internal ]; };
@@ -61,7 +61,7 @@ } ''
${builder}/bin/build -s $src -d $out/public ''; server = buildGoApplication { - pname = "website"; + pname = "server"; inherit version; CGO_ENABLED = 0; src = with lib.fileset; toSource {
@@ -69,7 +69,7 @@ root = ./..;
fileset = unions [ ./../go.mod ./../go.sum - ./../server.go + ./../cmd/server ./../internal ]; };
M nix/scripts.nixnix/scripts.nix
@@ -16,10 +16,10 @@ image = system: "nix build ${(mkAttr "image") system}";
in with pkgs; [ (writeShellScriptBin "watch-builder" '' - ${watchFlake} "direnv exec . watchexec -i server.go -i public -r go run ./cmd/build $@" + ${watchFlake} "direnv exec . watchexec -i cmd/server -i public -r go run ./cmd/build $@" '') (writeShellScriptBin "watch-server" '' - ${watchFlake} "direnv exec . watchexec -r go run ./server.go $@" + ${watchFlake} "direnv exec . watchexec -r go run ./cmd/server $@" '') (writeShellScriptBin "check-licenses" '' ${go-licenses}/bin/go-licenses check --include_tests ./... --disallowed_types=restricted,forbidden