Skip to content

Commit

Permalink
reset
Browse files Browse the repository at this point in the history
  • Loading branch information
damianszczepanik committed Oct 13, 2023
1 parent 2bfe028 commit e7269ca
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,9 @@ RUN apk add --no-cache --update git tzdata ca-certificates

RUN \
if [ -z "$CI" ] ; then \
echo "runs outside of CI"; \
version=$(git rev-parse --abbrev-ref HEAD)-$(git log -1 --format=%h)-$(date +%Y%m%dT%H:%M:%S); \
else; \
version=${GIT_BRANCH}-${GITHUB_SHA:0:7}-$(date +%Y%m%dT%H:%M:%S); \
fi; \
echo "version=$version"; \
echo "runs outside of CI" && version=$(git rev-parse --abbrev-ref HEAD)-$(git log -1 --format=%h)-$(date +%Y%m%dT%H:%M:%S); \
else version=${GIT_BRANCH}-${GITHUB_SHA:0:7}-$(date +%Y%m%dT%H:%M:%S); fi && \
echo "version=$version" && \
cd app && go build -o /build/doku -ldflags "-X main.revision=${version} -s -w"


Expand Down

0 comments on commit e7269ca

Please sign in to comment.