Files
tomswall/Makefile
T
unkinben 2a3eb3b04d Initial scaffold for tomswall
Spiritual successor to shorewall — manages nftables directly via
google/nftables. Reads a single YAML config covering zones, interfaces,
hosts, policy, rules, snat, and named portgroups. Computes differential
changes against the running nftables state and applies them atomically.
Supports detecting and purging rules added outside of tomswall.
2026-06-28 23:43:16 +10:00

26 lines
555 B
Makefile

BINARY := tomswall
MODULE := git.unkin.net/unkin/tomswall
PREFIX := /usr/local
CONFDIR := /etc/tomswall
.PHONY: build install clean check test
build:
go build -o $(BINARY) ./cmd/tomswall
install: build
install -Dm755 $(BINARY) $(DESTDIR)$(PREFIX)/sbin/$(BINARY)
install -Dm644 tomswall.example.yaml $(DESTDIR)$(CONFDIR)/tomswall.example.yaml
@if [ ! -f $(DESTDIR)$(CONFDIR)/tomswall.yaml ]; then \
install -Dm644 tomswall.example.yaml $(DESTDIR)$(CONFDIR)/tomswall.yaml; \
fi
clean:
rm -f $(BINARY)
check:
go vet ./...
test:
go test ./...