-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
28 lines (24 loc) · 1.1 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# re-generate protos...this only needs to run if you want to make changes to proto since these are
# currently checked into the repository, which is subject to change
proto-gen:
rm -rf gen
buf generate buf.build/opencensus/opencensus
buf generate buf.build/prometheus/client-model
buf generate buf.build/opentelemetry/opentelemetry
buf generate buf.build/googleapis/googleapis
buf generate buf.build/cncf/xds
buf generate buf.build/envoyproxy/protoc-gen-validate
buf generate buf.build/envoyproxy/envoy
## builds locally and copies into distroless container server runs on port 8080
build-image:
GOOS=linux GOARCH=amd64 go build -o ratelimit-example server/main.go
docker build -t ratelimit-example:latest .
## build, re-tag as #v3 and push container
docker-push:
docker tag ratelimit-example:latest emissaryingress/ratelimit-example:v3
docker push emissaryingress/ratelimit-example:v3
## applies the necessary yaml to setup ratelimit service
apply-yaml:
kubectl apply -f ./k8s/ratelimit-example.yaml
kubectl apply -f ./k8s/emissary-ratelimit-service.yaml
kubectl apply -f ./k8s/quote-mapping-ratelimited.yaml