This commit is contained in:
20
Makefile
20
Makefile
@@ -1,18 +1,4 @@
|
||||
.PHONY: help certs switch
|
||||
.PHONY: lock
|
||||
|
||||
help:
|
||||
@grep -E '^[a-zA-Z_-]+:.*##' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*## "}; {printf " \033[36m%-20s\033[0m %s\n", $$1, $$2}'
|
||||
|
||||
switch:
|
||||
sudo nixos-rebuild switch --flake .#haschel
|
||||
|
||||
certs:
|
||||
@for unit in $$(systemctl list-units 'acme-order-renew-*' --all --plain --no-legend --state=inactive --state=failed | awk '{print $$1}'); do \
|
||||
domain=$$(echo "$$unit" | sed 's/acme-order-renew-//;s/\.service//'); \
|
||||
if [ ! -f "/var/lib/acme/$$domain/fullchain.pem" ]; then \
|
||||
echo "Requesting cert for $$domain..."; \
|
||||
sudo systemctl start "$$unit" & \
|
||||
fi; \
|
||||
done; \
|
||||
wait; \
|
||||
echo "Done. Check status with: systemctl list-units 'acme-order-renew-*' --all --state=failed"
|
||||
lock:
|
||||
nix flake lock
|
||||
|
||||
Reference in New Issue
Block a user