Skip to content

Commit

Permalink
fix automated releases broken due to workspace location misconfig aft…
Browse files Browse the repository at this point in the history
…er go mod migration
  • Loading branch information
mumoshu committed May 4, 2019
1 parent 950bd23 commit 59b254e
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
13 changes: 10 additions & 3 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ jobs:
- image: circleci/golang:1.12.4
environment:
GOPATH: /go
working_directory: /home/circleci/workspace/helmfile
steps:
- checkout
- restore_cache:
Expand All @@ -29,6 +30,7 @@ jobs:
GOPATH: /go
docker:
- image: circleci/golang:1.12.4
working_directory: /home/circleci/workspace/helmfile
steps:
- checkout
- restore_cache:
Expand Down Expand Up @@ -89,16 +91,21 @@ jobs:

release:
docker:
- image: circleci/golang:1.12.1
working_directory: /go/src/github.com/roboll/helmfile
- image: circleci/golang:1.12.4
working_directory: /home/circleci/workspace/helmfile
steps:
- checkout
- restore_cache:
keys:
- go-mod-cache-v1-{{ checksum "./go.sum" }}
- go-mod-cache-v1-
- setup_remote_docker
- run:
command: |
docker login -u="$DOCKER_USER" -p="$DOCKER_PASS" quay.io
make tools
BUILD_URL="$CIRCLE_BUILD_URL" make push release
go mod vendor
ORG=roboll BUILD_URL="$CIRCLE_BUILD_URL" make push release
workflows:
version: 2
Expand Down
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
FROM golang:1.12.4-alpine3.9 as builder

RUN apk add --no-cache make git
WORKDIR /go/src/github.com/roboll/helmfile/
COPY . /go/src/github.com/roboll/helmfile/
WORKDIR /workspace/helmfile
COPY . /workspace/helmfile
RUN make static-linux

# -----------------------------------------------------------------------------
Expand All @@ -24,6 +24,6 @@ RUN mkdir -p "$(helm home)/plugins"
RUN helm plugin install https://github.com/databus23/helm-diff && \
helm plugin install https://github.com/futuresimple/helm-secrets

COPY --from=builder /go/src/github.com/roboll/helmfile/dist/helmfile_linux_amd64 /usr/local/bin/helmfile
COPY --from=builder /workspace/helmfile/dist/helmfile_linux_amd64 /usr/local/bin/helmfile

CMD ["/usr/local/bin/helmfile"]

0 comments on commit 59b254e

Please sign in to comment.