Skip to content

Commit 91bf8c2

Browse files
authored
CircleCI fixes (#667)
1 parent 5045c12 commit 91bf8c2

File tree

1 file changed

+42
-21
lines changed

1 file changed

+42
-21
lines changed

.circleci/config.yml

Lines changed: 42 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,35 @@ commands:
3535
- setup_remote_docker:
3636
docker_layer_caching: true
3737

38+
relocate-docker-storage:
39+
steps:
40+
- run:
41+
name: Relocate docker overlay2 dir
42+
command: |
43+
sudo systemctl stop docker
44+
sudo mkdir -p /var2/lib/docker
45+
sudo mv /var/lib/docker/overlay2 /var2/lib/docker
46+
sudo mkdir /var/lib/docker/overlay2
47+
sudo mount --bind /var2/lib/docker/overlay2 /var/lib/docker/overlay2
48+
sudo systemctl start docker
49+
3850
setup-automation:
3951
steps:
4052
- run:
4153
name: Setup automation
4254
command: |
55+
git submodule update --init opt/readies
4356
./opt/readies/bin/getpy3
4457
./opt/system-setup.py
4558
59+
setup-build-system:
60+
steps:
61+
- setup-automation
62+
- run:
63+
name: Setup build system
64+
command: |
65+
./opt/system-setup.py
66+
4667
build-steps:
4768
parameters:
4869
platform:
@@ -57,7 +78,7 @@ commands:
5778
keys:
5879
- v1-dependencies-{{ checksum "get_deps.sh" }}
5980
# If no exact match is found will get dependencies from source
60-
- setup-automation
81+
- setup-build-system
6182
- run:
6283
name: Install dependencies
6384
command: |
@@ -98,28 +119,18 @@ commands:
98119
steps:
99120
- abort_for_docs
100121
- checkout
122+
- relocate-docker-storage
101123
- run:
102-
name: Relocate docker overlay2 dir
103-
command: |
104-
sudo systemctl stop docker
105-
sudo mkdir -p /var2/lib/docker
106-
sudo mv /var/lib/docker/overlay2 /var2/lib/docker
107-
sudo mkdir /var/lib/docker/overlay2
108-
sudo mount --bind /var2/lib/docker/overlay2 /var/lib/docker/overlay2
109-
sudo systemctl start docker
110-
- run:
111-
name: Setup
112-
command: |
113-
git submodule update --init --recursive
114-
./opt/readies/bin/getpy3
124+
name: Submodule checkout
125+
command: git submodule update --init --recursive
126+
- setup-automation
115127
- run:
116128
name: Build for platform
117129
command: |
118-
docker login -u redisfab -p $DOCKER_REDISFAB_PWD
119130
pushd opt/build/docker
120131
for osnick in bionic xenial; do
121-
make CPU=1 OSNICK=$osnick ARTIFACTS=1 VERBOSE=1 build publish
122-
make GPU=1 OSNICK=$osnick ARTIFACTS=1 VERBOSE=1 build publish
132+
make CPU=1 OSNICK=$osnick ARTIFACTS=1 VERBOSE=1 build
133+
make GPU=1 OSNICK=$osnick ARTIFACTS=1 VERBOSE=1 build
123134
done
124135
popd > /dev/null
125136
logstar=bin/artifacts/tests-logs-cpu.tgz
@@ -128,6 +139,16 @@ commands:
128139
if [[ -e $logstar ]]; then tar -C $logsdir -xzf $logstar; fi
129140
(cd bin/artifacts; tar -cf snapshots.tar snapshots/)
130141
no_output_timeout: 40m
142+
- early_return_for_forked_pull_requests
143+
- run:
144+
name: Build for platform (publish)
145+
command: |
146+
docker login -u redisfab -p $DOCKER_REDISFAB_PWD
147+
cd opt/build/docker
148+
for osnick in bionic xenial; do
149+
make CPU=1 OSNICK=$osnick VERBOSE=1 publish
150+
make GPU=1 OSNICK=$osnick VERBOSE=1 publish
151+
done
131152
- persist_to_workspace:
132153
root: bin/
133154
paths:
@@ -159,7 +180,7 @@ jobs:
159180
- run:
160181
name: Submodule checkout
161182
command: git submodule update --init --recursive
162-
- setup-automation
183+
- setup-build-system
163184
- run:
164185
name: lint
165186
command: |
@@ -194,7 +215,7 @@ jobs:
194215
keys:
195216
- build-dependencies-{{ checksum "get_deps.sh" }}
196217
# If no exact match is found will get dependencies from source
197-
- setup-automation
218+
- setup-build-system
198219
- run:
199220
name: Install dependencies
200221
command: |
@@ -228,11 +249,11 @@ jobs:
228249
keys:
229250
- build-dependencies-{{ checksum "get_deps.sh" }}
230251
# If no exact match is found will get dependencies from source
231-
- setup-automation
252+
- setup-build-system
232253
- run:
233254
name: Install dependencies
234255
command: |
235-
./opt/readies/bin/getredis -v 6 --valgrind --force
256+
./opt/readies/bin/getredis -v 6.0 --valgrind --force
236257
./get_deps.sh cpu
237258
- run:
238259
name: Build for valgrind

0 commit comments

Comments
 (0)