summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShulhan <m.shulhan@gmail.com>2020-05-07 17:38:22 +0700
committerShulhan <m.shulhan@gmail.com>2020-05-07 17:38:22 +0700
commit19d264bf06a1a2c4678565a24b920649f2da0e98 (patch)
tree80be765f069238121171ab543832c6a5e00def7c
parentdf883a5b2e27099fc0e08ca073d18d43842ca522 (diff)
downloadrescached-19d264bf06a1a2c4678565a24b920649f2da0e98.tar.xz
Makefile: add task to deploy rescached to remote server
-rw-r--r--Makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index f61072e..fcd7601 100644
--- a/Makefile
+++ b/Makefile
@@ -7,6 +7,7 @@
.PHONY: test test.prof coverbrowse lint
.PHONY: doc
.PHONY: clean distclean
+.PHONY: deploy
SRC:=$(shell go list -f '{{$$d:=.Dir}} {{ range .GoFiles }}{{$$d}}/{{.}} {{end}}' ./...)
SRC_TEST:=$(shell go list -f '{{$$d:=.Dir}} {{ range .TestGoFiles }}{{$$d}}/{{.}} {{end}}' ./...)
@@ -147,3 +148,7 @@ uninstall-macos: uninstall-common
launchctl stop info.kilabit.rescached
launchctl unload info.kilabit.rescached
rm -f /Library/LaunchDaemons/info.kilabit.rescached.plist
+
+deploy:
+ CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build ./cmd/rescached
+ rsync --progress ./rescached dns-server:~/bin/rescached