File tree Expand file tree Collapse file tree 3 files changed +28
-6
lines changed Expand file tree Collapse file tree 3 files changed +28
-6
lines changed Original file line number Diff line number Diff line change @@ -84,6 +84,14 @@ pipeline {
84
84
}
85
85
}
86
86
steps {
87
+ // Docker image check
88
+ sh ''' docker run --rm \
89
+ -v /var/run/docker.sock:/var/run/docker.sock \
90
+ -v "$(pwd)/docker:/app" \
91
+ -e CI=true \
92
+ wagoodman/dive:latest --ci-config /app/.dive-ci \
93
+ "${IMAGE}:${BRANCH_LOWER}-ci-${BUILD_NUMBER}"
94
+ '''
87
95
// Bring up a stack
88
96
sh ' docker-compose up -d fullstack'
89
97
sh ' ./scripts/wait-healthy $(docker-compose ps -q fullstack) 120'
@@ -199,9 +207,9 @@ pipeline {
199
207
post {
200
208
always {
201
209
sh ' docker-compose down --rmi all --remove-orphans --volumes -t 30'
202
- sh ' ./scripts/build-cleanup'
203
- sh ' echo Reverting ownership'
204
- sh ' docker run --rm -v $(pwd):/data node :latest chown -R "$(id -u):$(id -g)" /data'
210
+ sh ' ./scripts/ci/ build-cleanup'
211
+ echo ' Reverting ownership'
212
+ sh ' docker run --rm -v $(pwd):/data jc21/gotools :latest chown -R "$(id -u):$(id -g)" /data'
205
213
}
206
214
success {
207
215
juxtapose event : ' success'
Original file line number Diff line number Diff line change
1
+ rules:
2
+ # If the efficiency is measured below X%, mark as failed.
3
+ # Expressed as a ratio between 0-1.
4
+ lowestEfficiency: 0.99
5
+
6
+ # If the amount of wasted space is at least X or larger than X, mark as failed.
7
+ # Expressed in B, KB, MB, and GB.
8
+ highestWastedBytes: 15MB
9
+
10
+ # If the amount of wasted space makes up for X% or more of the image, mark as failed.
11
+ # Note: the base image layer is NOT included in the total image size.
12
+ # Expressed as a ratio between 0-1; fails if the threshold is met or crossed.
13
+ highestUserWastedPercent: 0.02
14
+
Original file line number Diff line number Diff line change 1
1
#! /bin/bash -e
2
2
3
3
DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " && pwd) "
4
- . " $DIR /.common.sh"
4
+ . " $DIR /../. common.sh"
5
5
6
6
# Ensure docker-compose exists
7
7
if hash docker 2> /dev/null; then
8
- cd " ${DIR} /.."
8
+ cd " ${DIR} /../.. "
9
9
echo -e " ${BLUE} ❯ ${CYAN} Build Cleanup ...${RESET} "
10
10
11
- docker run --rm -e CI=true -v " $( pwd) :/app" -w /app node :latest rm -rf \
11
+ docker run --rm -e CI=true -v " $( pwd) :/app" -w /app jc21/gotools :latest rm -rf \
12
12
/app/frontend/node_modules \
13
13
/app/docs/node_modules \
14
14
/app/docs/.vuepress/dist
You can’t perform that action at this time.
0 commit comments