4 nixops-vmdk: $(dir $(NIXOPS_STATE))/virtualbox/nixops.vmdk
5 .PHONY: $(dir $(NIXOPS_STATE))/virtualbox/nixops.vmdk
6 $(dir $(NIXOPS_STATE))/virtualbox/nixops.vmdk:
7 # NOTE: user's TMPDIR may be too small
9 time nix $(NIX_FLAGS) build \
10 --out-link .cache/nixops/virtualbox \
11 --argstr system x86_64-linux \
12 -f "<nixpkgs-commonsoft/build/pkgs/installer/nixops-virtualbox>"
17 nixops-create: $(dir $(NIXOPS_STATE))
18 $(if $(filter $(NIXOPS_DEPLOYMENT),$(nixops-deployment)),,\
23 nixops-modify: $(NIXOPS_STATE)
28 $(dir $(NIXOPS_STATE)):
30 nixops-deployment = $(shell \
31 test ! -f $(NIXOPS_STATE) || \
32 sqlite3 $(NIXOPS_STATE) \
33 "select value from DeploymentAttrs \
34 where name='name' and value='$(NIXOPS_DEPLOYMENT)';")
39 nixops-deploy: nixops-create
40 time nixops deploy $(NIXOPS_OPTS) $(NIX_DEPLOY_FLAGS)
42 #time disnixos-env --use-nixops \
43 # -s install/disnix/services.nix \
44 # -d install/disnix/distribution.nix \
45 # -n install/logical.nix \
46 # -n install/physical.nix
47 %/offline: NIX_BUILD_FLAGS+=--option substituters ""
48 %/offline: NIX_DEPLOY_FLAGS+=--option substituters ""
51 %/verbose: NIX_FLAGS+=-v -v -v
61 nixops-state-dump: $(NIXOPS_STATE)
62 sqlite3 $(NIXOPS_STATE) .dump
64 sqlite3 $(NIXOPS_STATE) \
65 'update ResourceAttrs set value = "$(IPv4)" where name="privateIpv4"'