-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
15 lines (10 loc) · 988 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
VERSION=0.0.1
all: build
build:
go build -ldflags "-X github.com/freitagsrunde/k4ever-backend/internal/context.GitCommit=$$(git rev-parse HEAD) -X github.com/freitagsrunde/k4ever-backend/internal/context.GitBranch=$$(git rev-parse --abbrev-ref HEAD) -X github.com/freitagsrunde/k4ever-backend/internal/context.BuildTime=$$(date -u --iso-8601=seconds) -X github.com/freitagsrunde/k4ever-backend/internal/context.version=${VERSION}"
run:
go run -ldflags "-X github.com/freitagsrunde/k4ever-backend/internal/context.GitCommit=$$(git rev-parse HEAD) -X github.com/freitagsrunde/k4ever-backend/internal/context.GitBranch=$$(git rev-parse --abbrev-ref HEAD) -X github.com/freitagsrunde/k4ever-backend/internal/context.BuildTime=$$(date -u --iso-8601=seconds) -X github.com/freitagsrunde/k4ever-backend/internal/context.version=${VERSION}"
docker-build:
docker build -t freitagsrunde/k4ever-backend -t freitagsrunde/k4ever-backend:${VERSION} .
deploy:
scripts/docker_push.sh ${VERSION}