Skip to content
This repository was archived by the owner on Oct 13, 2023. It is now read-only.

Commit 02c5476

Browse files
authored
Merge pull request #2048 from thaJeztah/19.03_backport_ci_improvements
[19.03 backport] CI and testing improvements Upstream-commit: 578ab52ece34b084621954e0b543003410cdbe84 Component: cli
2 parents 8493931 + ae6f7fe commit 02c5476

4 files changed

Lines changed: 42 additions & 33 deletions

File tree

components/cli/.dockerignore

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
1+
.dockerignore
12
.git
2-
build
3+
.gitignore
4+
appveyor.yml
5+
build
6+
circle.yml

components/cli/Jenkinsfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,9 @@ wrappedNode(label: 'linux && x86_64', cleanWorkspace: true) {
55

66
stage "Run end-to-end test suite"
77
sh "docker version"
8+
sh "docker info"
89
sh "E2E_UNIQUE_ID=clie2e${BUILD_NUMBER} \
910
IMAGE_TAG=clie2e${BUILD_NUMBER} \
10-
make -f docker.Makefile test-e2e"
11+
DOCKER_BUILDKIT=1 make -f docker.Makefile test-e2e"
1112
}
1213
}

components/cli/circle.yml

Lines changed: 35 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -4,35 +4,39 @@ jobs:
44

55
lint:
66
working_directory: /work
7-
docker: [{image: 'docker:18.03-git'}]
7+
docker: [{image: 'docker:18.09-git'}]
8+
environment:
9+
DOCKER_BUILDKIT: 1
810
steps:
911
- checkout
1012
- setup_remote_docker:
11-
version: 18.03.1-ce
12-
reusable: true
13-
exclusive: false
13+
version: 18.09.3
14+
reusable: true
15+
exclusive: false
1416
- run:
1517
command: docker version
1618
- run:
1719
name: "Lint"
1820
command: |
19-
docker build -f dockerfiles/Dockerfile.lint --tag cli-linter:$CIRCLE_BUILD_NUM .
21+
docker build --progress=plain -f dockerfiles/Dockerfile.lint --tag cli-linter:$CIRCLE_BUILD_NUM .
2022
docker run --rm cli-linter:$CIRCLE_BUILD_NUM
2123
2224
cross:
2325
working_directory: /work
24-
docker: [{image: 'docker:18.03-git'}]
26+
docker: [{image: 'docker:18.09-git'}]
27+
environment:
28+
DOCKER_BUILDKIT: 1
2529
parallelism: 3
2630
steps:
2731
- checkout
2832
- setup_remote_docker:
29-
version: 18.03.1-ce
30-
reusable: true
31-
exclusive: false
33+
version: 18.09.3
34+
reusable: true
35+
exclusive: false
3236
- run:
3337
name: "Cross"
3438
command: |
35-
docker build -f dockerfiles/Dockerfile.cross --tag cli-builder:$CIRCLE_BUILD_NUM .
39+
docker build --progress=plain -f dockerfiles/Dockerfile.cross --tag cli-builder:$CIRCLE_BUILD_NUM .
3640
name=cross-$CIRCLE_BUILD_NUM-$CIRCLE_NODE_INDEX
3741
docker run \
3842
-e CROSS_GROUP=$CIRCLE_NODE_INDEX \
@@ -46,18 +50,20 @@ jobs:
4650

4751
test:
4852
working_directory: /work
49-
docker: [{image: 'docker:18.03-git'}]
53+
docker: [{image: 'docker:18.09-git'}]
54+
environment:
55+
DOCKER_BUILDKIT: 1
5056
steps:
5157
- checkout
5258
- setup_remote_docker:
53-
version: 18.03.1-ce
54-
reusable: true
55-
exclusive: false
59+
version: 18.09.3
60+
reusable: true
61+
exclusive: false
5662
- run:
5763
name: "Unit Test with Coverage"
5864
command: |
5965
mkdir -p test-results/unit-tests
60-
docker build -f dockerfiles/Dockerfile.dev --tag cli-builder:$CIRCLE_BUILD_NUM .
66+
docker build --progress=plain -f dockerfiles/Dockerfile.dev --tag cli-builder:$CIRCLE_BUILD_NUM .
6167
docker run \
6268
-e GOTESTSUM_JUNITFILE=/tmp/junit.xml \
6369
--name \
@@ -82,34 +88,38 @@ jobs:
8288

8389
validate:
8490
working_directory: /work
85-
docker: [{image: 'docker:18.03-git'}]
91+
docker: [{image: 'docker:18.09-git'}]
92+
environment:
93+
DOCKER_BUILDKIT: 1
8694
steps:
8795
- checkout
8896
- setup_remote_docker:
89-
version: 18.03.1-ce
90-
reusable: true
91-
exclusive: false
97+
version: 18.09.3
98+
reusable: true
99+
exclusive: false
92100
- run:
93101
name: "Validate Vendor, Docs, and Code Generation"
94102
command: |
95103
rm -f .dockerignore # include .git
96-
docker build -f dockerfiles/Dockerfile.dev --tag cli-builder-with-git:$CIRCLE_BUILD_NUM .
104+
docker build --progress=plain -f dockerfiles/Dockerfile.dev --tag cli-builder-with-git:$CIRCLE_BUILD_NUM .
97105
docker run --rm cli-builder-with-git:$CIRCLE_BUILD_NUM \
98106
make ci-validate
99107
no_output_timeout: 15m
100108
shellcheck:
101109
working_directory: /work
102-
docker: [{image: 'docker:18.03-git'}]
110+
docker: [{image: 'docker:18.09-git'}]
111+
environment:
112+
DOCKER_BUILDKIT: 1
103113
steps:
104114
- checkout
105115
- setup_remote_docker:
106-
version: 18.03.1-ce
107-
reusable: true
108-
exclusive: false
116+
version: 18.09.3
117+
reusable: true
118+
exclusive: false
109119
- run:
110120
name: "Run shellcheck"
111121
command: |
112-
docker build -f dockerfiles/Dockerfile.shellcheck --tag cli-validator:$CIRCLE_BUILD_NUM .
122+
docker build --progress=plain -f dockerfiles/Dockerfile.shellcheck --tag cli-validator:$CIRCLE_BUILD_NUM .
113123
docker run --rm cli-validator:$CIRCLE_BUILD_NUM \
114124
make shellcheck
115125
workflows:

components/cli/dockerfiles/Dockerfile.e2e

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,12 @@
11
ARG GO_VERSION=1.12.8
22

3-
FROM docker/containerd-shim-process:a4d1531 AS containerd-shim-process
4-
53
# Use Debian based image as docker-compose requires glibc.
64
FROM golang:${GO_VERSION}
75

86
RUN apt-get update && apt-get install -y \
97
build-essential \
108
curl \
119
openssl \
12-
btrfs-tools \
13-
libapparmor-dev \
14-
libseccomp-dev \
15-
iptables \
1610
openssh-client \
1711
&& rm -rf /var/lib/apt/lists/*
1812

0 commit comments

Comments
 (0)