aboutsummaryrefslogtreecommitdiff
path: root/nixops
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2020-05-08 01:00:50 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2020-05-08 01:00:50 +0200
commit7ff0f7be4890ffd5d6af614fcade3d64eaa66ffc (patch)
treebc85df41a9a21e7448da54ee57be9f732a271dc2 /nixops
parentf5761aac8dbfb4af91c232f2b52d1353c899abda (diff)
downloadNix-7ff0f7be4890ffd5d6af614fcade3d64eaa66ffc.tar.gz
Nix-7ff0f7be4890ffd5d6af614fcade3d64eaa66ffc.tar.zst
Nix-7ff0f7be4890ffd5d6af614fcade3d64eaa66ffc.zip
Improve makefile recipes
Diffstat (limited to 'nixops')
-rw-r--r--nixops/Makefile21
1 files changed, 13 insertions, 8 deletions
diff --git a/nixops/Makefile b/nixops/Makefile
index e52e973..c521682 100644
--- a/nixops/Makefile
+++ b/nixops/Makefile
@@ -27,11 +27,16 @@ setup:
27.PHONY: setup 27.PHONY: setup
28 28
29###### Nixops regular tasks 29###### Nixops regular tasks
30TARGET ?=
30NIXOPS_ARGS ?= 31NIXOPS_ARGS ?=
32ifdef TARGET
33 override NIXOPS_ARGS +=--include=$(TARGET)
34endif
35SSH_ARGS ?=
36
31nixops: 37nixops:
32 $(NIXOPS_PRIV) $(NIXOPS_ARGS) 38 $(NIXOPS_PRIV) $(NIXOPS_ARGS)
33 39
34SSH_ARGS ?=
35ssh-eldiron: 40ssh-eldiron:
36 $(NIXOPS_PRIV) ssh eldiron -- $(SSH_ARGS) 41 $(NIXOPS_PRIV) ssh eldiron -- $(SSH_ARGS)
37 42
@@ -49,25 +54,25 @@ info:
49 $(NIXOPS_PRIV) info 54 $(NIXOPS_PRIV) info
50 55
51debug: 56debug:
52 $(NIXOPS_PRIV) deploy --build-only --show-trace 57 $(NIXOPS_PRIV) deploy --build-only --show-trace $(NIXOPS_ARGS)
53 58
54dry-run: 59dry-run:
55 $(NIXOPS_PRIV) deploy --dry-run 60 $(NIXOPS_PRIV) deploy --dry-run $(NIXOPS_ARGS)
56 61
57build: 62build:
58 $(NIXOPS_PRIV) deploy --build-only --max-jobs 1 63 $(NIXOPS_PRIV) deploy --build-only $(NIXOPS_ARGS)
59 64
60upload: 65upload:
61 $(NIXOPS_PRIV) deploy --copy-only 66 $(NIXOPS_PRIV) deploy --copy-only $(NIXOPS_ARGS)
62 67
63deploy: 68deploy:
64 $(NIXOPS_PRIV) deploy 69 $(NIXOPS_PRIV) deploy $(NIXOPS_ARGS)
65 70
66deploy-reboot: 71deploy-reboot:
67 $(NIXOPS_PRIV) deploy --force-reboot 72 $(NIXOPS_PRIV) deploy --force-reboot $(NIXOPS_ARGS)
68 73
69reboot: 74reboot:
70 $(NIXOPS_PRIV) reboot --include=eldiron 75 $(NIXOPS_PRIV) reboot --include=$(TARGET)
71.PHONY: nixops ssh-eldiron info debug dry-run build upload deploy deploy-reboot reboot 76.PHONY: nixops ssh-eldiron info debug dry-run build upload deploy deploy-reboot reboot
72 77
73###### Cleanup generations and garbage collection 78###### Cleanup generations and garbage collection