File tree Expand file tree Collapse file tree 3 files changed +6
-10
lines changed Expand file tree Collapse file tree 3 files changed +6
-10
lines changed Original file line number Diff line number Diff line change 18
18
command : " go env"
19
19
- go/load-cache :
20
20
key : go-mod-v6-{{ checksum "go.sum" }}
21
- - add_ssh_keys
22
21
- go/mod-download
23
22
- go/save-cache :
24
23
key : go-mod-v6-{{ checksum "go.sum" }}
@@ -46,15 +45,13 @@ jobs:
46
45
resource_class : large
47
46
steps :
48
47
- checkout
49
- - add_ssh_keys
50
48
- aws-ecr/build-image :
51
49
push-image : false
52
50
dockerfile : Dockerfile
53
51
path : ./
54
52
build-path : ./
55
53
tag : " $CIRCLE_SHA1,$CIRCLE_TAG"
56
54
repo : " $CIRCLE_PROJECT_REPONAME"
57
- extra-build-args : " --secret id=sshKey,src=/home/circleci/.ssh/$DEPLOY_KEY_NAME"
58
55
- run :
59
56
name : Save Docker image to export it to workspace
60
57
command : |
@@ -93,6 +90,10 @@ workflows:
93
90
filters :
94
91
tags :
95
92
only : /.*/
93
+ branches :
94
+ only :
95
+ - main
96
+ - dev
96
97
- push_docker :
97
98
requires :
98
99
- build_docker
Original file line number Diff line number Diff line change @@ -11,16 +11,11 @@ RUN apk add --no-cache --update openssh git make build-base linux-headers libc-d
11
11
pkgconfig zeromq-dev musl-dev alpine-sdk libsodium-dev \
12
12
libzmq-static libsodium-static gcc
13
13
14
- # Load private repos SSH deploy key and configure ssh
15
- RUN mkdir -p /root/.ssh && ssh-keyscan github.com >> /root/.ssh/known_hosts
16
- RUN git config --global url.
"[email protected] :" .insteadOf
"https://github.com/"
17
- ENV GOPRIVATE=github.com/babylonchain/*
18
-
19
14
# Build
20
15
WORKDIR /go/src/github.com/babylonchain/cli-tools
21
16
# Cache dependencies
22
17
COPY go.mod go.sum /go/src/github.com/babylonchain/cli-tools/
23
- RUN --mount=type=secret,id=sshKey,target=/root/.ssh/id_rsa go mod download
18
+ RUN go mod download
24
19
# Copy the rest of the files
25
20
COPY ./ /go/src/github.com/babylonchain/cli-tools/
26
21
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ $(BUILDDIR)/:
29
29
mkdir -p $(BUILDDIR ) /
30
30
31
31
build-docker :
32
- $(DOCKER ) build --secret id=sshKey,src= ${BBN_PRIV_DEPLOY_KEY} -- tag babylonchain/cli-tools -f Dockerfile \
32
+ $(DOCKER ) build --tag babylonchain/cli-tools -f Dockerfile \
33
33
$(shell git rev-parse --show-toplevel)
34
34
35
35
.PHONY : build build-docker install tests
You can’t perform that action at this time.
0 commit comments