Add server directive to Makefile

Builds server config, copies to server and deletes result after
This commit is contained in:
Evie Litherland-Smith 2024-12-28 08:06:53 +00:00
parent 9242be4f00
commit 9b7f35ea3d

View file

@ -1,4 +1,4 @@
.PHONY: default build flathub
.PHONY: default build server flathub
HOST := $(shell hostname)
@ -7,5 +7,10 @@ default: build
build:
nix build --no-link --keep-going .#nixosConfigurations.$(HOST).config.system.build.toplevel
server:
nixos-rebuild build --flake .#Legion
nix copy ./result --to ssh://legion
rm ./result
flathub:
flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo