Skip to content

Commit cf4c7d7

Browse files
author
zhilingc
committed
Add cli
1 parent 400b20b commit cf4c7d7

File tree

18 files changed

+1714
-0
lines changed

18 files changed

+1714
-0
lines changed

Gopkg.lock

Lines changed: 273 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Gopkg.toml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
# Gopkg.toml example
2+
#
3+
# Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md
4+
# for detailed Gopkg.toml documentation.
5+
#
6+
# required = ["github.com/user/thing/cmd/thing"]
7+
# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"]
8+
#
9+
# [[constraint]]
10+
# name = "github.com/user/project"
11+
# version = "1.0.0"
12+
#
13+
# [[constraint]]
14+
# name = "github.com/user/project2"
15+
# branch = "dev"
16+
# source = "github.com/myfork/project2"
17+
#
18+
# [[override]]
19+
# name = "github.com/x/y"
20+
# version = "2.4.0"
21+
#
22+
# [prune]
23+
# non-go = false
24+
# go-tests = true
25+
# unused-packages = true
26+
27+
28+
[[constraint]]
29+
name = "github.com/ghodss/yaml"
30+
version = "1.0.0"
31+
32+
[[constraint]]
33+
name = "github.com/golang/protobuf"
34+
version = "1.2.0"
35+
36+
[[constraint]]
37+
name = "github.com/google/go-cmp"
38+
version = "0.2.0"
39+
40+
[[constraint]]
41+
name = "github.com/mitchellh/go-homedir"
42+
version = "1.0.0"
43+
44+
[[constraint]]
45+
name = "github.com/spf13/cobra"
46+
version = "0.0.3"
47+
48+
[[constraint]]
49+
name = "github.com/spf13/viper"
50+
version = "1.2.1"
51+
52+
[[constraint]]
53+
branch = "master"
54+
name = "golang.org/x/net"
55+
56+
[[constraint]]
57+
name = "google.golang.org/grpc"
58+
version = "1.15.0"
59+
60+
[prune]
61+
go-tests = true
62+
unused-packages = true

Makefile

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
.PHONY: go
2+
3+
build-deps:
4+
$(MAKE) -C protos gen-go
5+
dep ensure
6+
7+
build-cli:
8+
$(MAKE) -C cli build-all
9+
10+
install-cli:
11+
@$(MAKE) build-deps
12+
cd cli/feast && go install
13+
14+
build-docker:
15+
docker build -t $(registry)/feast-core:$(version) -f docker/core/Dockerfile .
16+
docker build -t $(registry)/feast-serving:$(version) -f docker/serving/Dockerfile .
17+
18+
build-push-docker:
19+
@$(MAKE) build-docker registry=$(registry) version=$(version)
20+
docker push $(registry)/feast-core:$(version)
21+
docker push $(registry)/feast-serving:$(version)
22+

cli/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
feast/yamls
2+
feast/feast

cli/Makefile

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
.PHONY: go
2+
3+
build-all:
4+
@$(MAKE) cli-linux cli-darwin
5+
6+
.PHONY: cli-linux
7+
cli-linux:
8+
mkdir -p bin
9+
export GOOS=linux; \
10+
export GOARCH=amd64; \
11+
mkdir -p bin/$$GOOS-$$GOARCH && go build -o bin/$$GOOS-$$GOARCH/feast feast/main.go
12+
13+
.PHONY: cli-darwin
14+
cli-darwin:
15+
export GOOS=darwin; \
16+
export GOARCH=amd64; \
17+
mkdir -p bin/$$GOOS-$$GOARCH && go build -o bin/$$GOOS-$$GOARCH/feast feast/main.go

0 commit comments

Comments
 (0)