forked from brave-intl/publishers
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
28 lines (23 loc) · 909 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
24
25
26
27
28
GIT_VERSION := $(shell git describe --abbrev=8 --dirty --always --tags)
GIT_COMMIT := $(shell git rev-parse --short HEAD)
BUILD_TIME := $(shell date +%s)
docker:
docker build --build-arg COMMIT=$(GIT_COMMIT) --build-arg VERSION=$(GIT_VERSION) \
--build-arg BUILD_TIME=$(BUILD_TIME) -t publishers:latest .
docker tag publishers:latest publishers:$(GIT_VERSION)
docker-dev-build:
docker-compose build
docker-dev:
docker-compose up
docker-test:
docker-compose up --detach postgres web
docker-compose run -e "RAILS_ENV=test" web sh -c "./scripts/entrypoint.sh && rails test && yarn test"
docker-compose down
k8:
kubectl delete -f web-deployment.yaml
kubectl delete services publishers
kubectl apply -f web-deployment.yaml
kubectl rollout status deployment.v1.apps/publishers
kubectl expose deployment publishers --type=NodePort --port=3000
kubectl get pods
minikube service publishers --url