-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
27 lines (20 loc) · 836 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
.PHONY: test up build run stop down docker-login image-push
test:
docker-compose -f test/docker-compose.yml up --build -d -V --force-recreate --remove-orphans
go test -race -count=1 -p 1 -race -coverpkg=./... -covermode=atomic -coverprofile=coverage.out ./...
docker-compose -f test/docker-compose.yml rm -sfv
rm -rf coverage.out
up:
docker-compose -f docker-compose.yml up --build -d -V --force-recreate --remove-orphans
build:
docker-compose -f docker-compose.yml up -d --force-recreate --remove-orphans --build
stop:
docker-compose stop
down:
docker-compose -f docker-compose.yml kill
docker-compose -f docker-compose.yml rm -sfv
docker-login:
docker login -u=${DOCKER_USERNAME} -p=${DOCKER_PASSWORD} ${DOCKER_REGISTRY}
image-push: docker-login
docker push ${IMAGE_NAME}:${VERSION}
docker push ${IMAGE_NAME}:latest