summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorgiri <hg0071052@techmahindra.com>2018-03-29 04:58:14 +0000
committergiri <hg0071052@techmahindra.com>2018-04-04 04:31:43 +0000
commit25865489e4ea236afc699f8b6c9c62fd92145af1 (patch)
tree60585e5ac33139184952a6ce21b646330ccab37e
parentda0b104514a8f3b2034a125a2ae9cba75341a3dc (diff)
Added Makefile for quorumclient
Added Makefile for quorumclient Change-Id: Iee3912a8a675c7eab2514fc9257ae97dfc8b7157 Issue-ID: AAF-205 Signed-off-by: giri <hg0071052@techmahindra.com>
-rw-r--r--sms-quorum/bin/Dockerfile2
-rw-r--r--sms-quorum/src/smsquorum/Makefile25
2 files changed, 26 insertions, 1 deletions
diff --git a/sms-quorum/bin/Dockerfile b/sms-quorum/bin/Dockerfile
index 1f3a2d5..2e1a191 100644
--- a/sms-quorum/bin/Dockerfile
+++ b/sms-quorum/bin/Dockerfile
@@ -6,4 +6,4 @@ LABEL maintainer="Girish Havaldar <hg0071052@techmahindra.com>"
ADD quorumclient /smsquorum/bin/quorumclient
RUN chmod +x /smsquorum/bin/quorumclient
-ENTRYPOINT ["/smsquorum/bin/quorumclient"] \ No newline at end of file
+ENTRYPOINT ["/smsquorum/bin/quorumclient"]
diff --git a/sms-quorum/src/smsquorum/Makefile b/sms-quorum/src/smsquorum/Makefile
new file mode 100644
index 0000000..d264de9
--- /dev/null
+++ b/sms-quorum/src/smsquorum/Makefile
@@ -0,0 +1,25 @@
+GOPATH := $(shell realpath "$(PWD)/../../")
+BINARY := quorumclient
+PLATFORM := linux
+
+export GOPATH ...
+
+all: test build
+deploy: test build
+
+build: format
+ CGO_ENABLED=0 GOOS=$(PLATFORM) go build -a \
+ -ldflags '-extldflags "-static"' \
+ -o $(GOPATH)/target/$(BINARY) -v quorumclient.go
+
+clean:
+ go clean
+ rm -f $(GOPATH)/target/$(BINARY)
+
+test:
+ @echo "Yet to Implement"
+
+format:
+ go fmt ./...
+
+.PHONY: test