NAS := luxick@192.168.3.3

.PHONY: deploy
deploy:
	GOOS=linux GOARCH=arm GOARM=7 go build -o datascape-arm .
	ssh $(NAS) 'kill $$(cat /share/homes/luxick/.local/bin/datascape.pid) 2>/dev/null; rm -f /share/homes/luxick/.local/bin/datascape.pid'
	scp datascape-arm $(NAS):/share/homes/luxick/.local/bin/datascape
	ssh $(NAS) /share/homes/luxick/.local/bin/datascape-start.sh
	rm datascape-arm
