forked from ethereum/go-ethereum
/
config.yml
71 lines (67 loc) · 1.99 KB
/
config.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
version: 2.1
jobs:
build-geth:
docker:
- image: cimg/go:1.18
resource_class: medium
steps:
- checkout
- run:
command: go run build/ci.go install
unit-test:
resource_class: medium
docker:
- image: cimg/go:1.18
steps:
- checkout
- run:
command: go run build/ci.go test
lint-geth:
resource_class: medium
docker:
- image: cimg/go:1.18
steps:
- checkout
- run:
command: go run build/ci.go lint
push-geth:
docker:
- image: cimg/base:2022.04
steps:
- when:
condition:
or:
- equal: [ optimism, <<pipeline.git.branch>> ]
- equal: [ optimism-history, <<pipeline.git.branch>> ]
steps:
- checkout
- setup_remote_docker:
version: 20.10.12
- run:
name: Build and push
command: |
echo "$DOCKER_PASS" | docker login -u "$DOCKER_USERNAME" --password-stdin
docker build -t "ethereumoptimism/op-geth:$CIRCLE_SHA1" -f Dockerfile .
docker tag "ethereumoptimism/op-geth:$CIRCLE_SHA1" "ethereumoptimism/op-geth:$CIRCLE_BRANCH"
docker push "ethereumoptimism/op-geth:$CIRCLE_SHA1"
docker push "ethereumoptimism/op-geth:$CIRCLE_BRANCH"
if [ $CIRCLE_BRANCH = "optimism" ]
then
docker tag "ethereumoptimism/op-geth:$CIRCLE_SHA1" "ethereumoptimism/op-geth:latest"
docker push "ethereumoptimism/op-geth:latest"
pwd
fi
# Below step is required to prevent CircleCI from barfing on a
# job with no steps
- run: echo 0
workflows:
main:
jobs:
- build-geth:
name: Build geth
- unit-test:
name: Run unit tests for geth
- lint-geth:
name: Run linter over geth
- push-geth:
name: Push geth