-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
23 lines (18 loc) · 941 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
.PHONY: proto build deploy
build: proto build-ci
build-ci:
CGO_ENABLED=0 go build -o client ./cmd/client/main.go
CGO_ENABLED=0 go build -o meshserver ./cmd/server/main.go
CGO_ENABLED=0 go build -o exporter ./cmd/exporter/main.go
proto:
protoc --go_out=./ --go-grpc_out=./ -I ./ proto/statusmanager.proto proto/controlplane.proto proto/administration.proto proto/ip.proto --validate_out="lang=go:./"
deploy: build
ssh meshover4 "sudo pkill client" || echo "$?"
ssh meshover5 "sudo pkill client" || echo "$?"
scp ./client meshover4:~/
scp ./client meshover5:~/
ssh meshover4 "nohup sudo ./client -controlserver 192.168.129.66:12384 -statusserver 192.168.129.66:12385 -frr nerdctl -coiladvertise -coilnatsources 10.0.0.0/8 &" &
ssh meshover5 "nohup sudo ./client -controlserver 192.168.129.66:12384 -statusserver 192.168.129.66:12385 -frr nerdctl -coiladvertise -coilnatsources 10.0.0.0/8 &" &
test:
go mod tidy
go test ./...