From da07dd611a7d01b7cba3805e625c9f5dea621f18 Mon Sep 17 00:00:00 2001 From: Anton Zadvorny Date: Sun, 1 Sep 2019 20:19:32 +0300 Subject: [PATCH] Clean caches after installing tools --- Dockerfile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index 12104fa..363771c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,14 +20,15 @@ RUN \ echo "${TZ}" > /etc/timezone && date RUN \ - go version - -RUN \ + # install golangci-lint go get -u -v github.com/golangci/golangci-lint/cmd/golangci-lint@v${GOLANGCI} && \ go install -ldflags "-X 'main.version=$(git describe --tags)' -X 'main.commit=$(git rev-parse --short HEAD)' -X 'main.date=$(date)'" github.com/golangci/golangci-lint/cmd/golangci-lint && \ - golangci-lint --version - -RUN \ + # install goswag go get -u -v github.com/swaggo/swag/cmd/swag@v${GOSWAG} && \ go install github.com/swaggo/swag/cmd/swag && \ + # cleanup + go clean -cache -modcache && \ + # print versions + go version && \ + golangci-lint --version && \ swag --version