Commit 12959356 authored by Janne Koschinski's avatar Janne Koschinski

Updated build scripts

parent 7b3eb892
......@@ -19,4 +19,4 @@ WORKDIR /
COPY --from=go_builder /go/src/app/app /app
COPY templates /templates
COPY --from=asset_builder /app/assets /assets
\ No newline at end of file
IMAGE :=$(shell basename $(shell git remote get-url origin) .git)
TAGS := $(shell git describe --always --tags HEAD)
.PHONY: build
docker build --pull -t $(IMAGE):$(TAGS) .
docker tag $(IMAGE):$(TAGS) $(IMAGE):latest
@echo Successfully tagged $(IMAGE):$(TAGS) as latest
.PHONY: push
push: build
docker push $(IMAGE):$(TAGS)
docker push $(IMAGE):latest
@echo Successfully pushed $(IMAGE):$(TAGS) as latest
TAGS=$(git describe --always --tags HEAD)
docker build -t $IMAGE:$TAGS .
docker tag $IMAGE:$TAGS $IMAGE:latest
echo Successfully tagged $IMAGE:latest
docker push $IMAGE:$TAGS
docker push $IMAGE:latest
\ No newline at end of file
TAGS=$(git describe --always --tags HEAD)
kubectl -n imghost set image deployment/$DEPLOYMENT $POD=$IMAGE:$TAGS
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment