forked from socallinuxexpo/scale-network
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
36 lines (28 loc) · 958 Bytes
/
Makefile
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
Command := $(firstword $(MAKECMDGOALS))
Arguments := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
default: show
bhyveImage:
@echo "nix building $(Arguments) bhyve Image"
nix build ".#nixosConfigurations.$(Arguments).config.system.build.bhyveImage" -o result-bhyveImage-$(Arguments)
qemuVm:
@echo "nix building $(Arguments) qemu VM"
nix build ".#nixosConfigurations.$(Arguments).config.system.build.vm" -o result-qemuVm-$(Arguments)
all: bhyveImage qemuVm
show:
@echo "A simple wrapper for nix build "$(Arguments)"!";
@echo "You will need NIXOS Installed!!! :-)";
@echo "Available test are:"
@echo
@ls nix/tests/.
@echo
@echo "Try typing make at the CLI and hit TAB (on your keyboard) for targets"
@echo
nix flake show;
nixtests:
@echo "Available test are:"
@ls nix/tests/.
@echo
@echo "nix building and running nixos $(Arguments) tests"
nix build ".#packages.x86_64-linux.scaleTests.$(Arguments)"
%::
@true