Skip to content

Commit 329554d

Browse files
committed
refactor(build): Clean up Docker steps for Ruby builder and improve error messages
1 parent da14504 commit 329554d

File tree

1 file changed

+12
-28
lines changed

1 file changed

+12
-28
lines changed

infra/build/functions/test_data/expected_trial_build_steps.json

Lines changed: 12 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -107,20 +107,20 @@
107107
]
108108
},
109109
{
110+
"name": "gcr.io/cloud-builders/docker",
110111
"args": [
111112
"pull",
112113
"gcr.io/oss-fuzz-base/base-builder-ruby-testing-mybranch"
113114
],
114-
"name": "gcr.io/cloud-builders/docker",
115115
"waitFor": "-"
116116
},
117117
{
118+
"name": "gcr.io/cloud-builders/docker",
118119
"args": [
119120
"tag",
120121
"gcr.io/oss-fuzz-base/base-builder-ruby-testing-mybranch",
121122
"gcr.io/oss-fuzz-base/base-builder-ruby"
122-
],
123-
"name": "gcr.io/cloud-builders/docker"
123+
]
124124
},
125125
{
126126
"name": "gcr.io/cloud-builders/docker",
@@ -138,22 +138,6 @@
138138
"gcr.io/oss-fuzz-base/base-builder-rust"
139139
]
140140
},
141-
{
142-
"name": "gcr.io/cloud-builders/docker",
143-
"args": [
144-
"pull",
145-
"gcr.io/oss-fuzz-base/base-builder-ruby-testing-mybranch"
146-
],
147-
"waitFor": "-"
148-
},
149-
{
150-
"name": "gcr.io/cloud-builders/docker",
151-
"args": [
152-
"tag",
153-
"gcr.io/oss-fuzz-base/base-builder-ruby-testing-mybranch",
154-
"gcr.io/oss-fuzz-base/base-builder-ruby"
155-
]
156-
},
157141
{
158142
"name": "gcr.io/cloud-builders/docker",
159143
"args": [
@@ -229,7 +213,7 @@
229213
"gcr.io/oss-fuzz/skcms",
230214
"bash",
231215
"-c",
232-
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/afl-address-x86_64 && compile || (echo \"********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine afl --architecture x86_64 skcms\n********************************************************************************\" && false)"
216+
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/afl-address-x86_64 && compile || (echo "********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine afl --architecture x86_64 skcms\n********************************************************************************" && false)"
233217
],
234218
"id": "compile-afl-address-x86_64"
235219
},
@@ -267,7 +251,7 @@
267251
"gcr.io/oss-fuzz-base/base-runner-testing-mybranch",
268252
"bash",
269253
"-c",
270-
"test_all.py || (echo \"********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine afl --architecture x86_64 skcms\npython infra/helper.py check_build --sanitizer address --engine afl --architecture x86_64 skcms\n********************************************************************************\" && false)"
254+
"test_all.py || (echo "********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine afl --architecture x86_64 skcms\npython infra/helper.py check_build --sanitizer address --engine afl --architecture x86_64 skcms\n********************************************************************************" && false)"
271255
],
272256
"id": "build-check-afl-address-x86_64"
273257
},
@@ -321,7 +305,7 @@
321305
"gcr.io/oss-fuzz/skcms",
322306
"bash",
323307
"-c",
324-
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/libfuzzer-address-x86_64 && compile || (echo \"********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************\" && false)"
308+
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/libfuzzer-address-x86_64 && compile || (echo "********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************" && false)"
325309
],
326310
"id": "compile-libfuzzer-address-x86_64"
327311
},
@@ -359,7 +343,7 @@
359343
"gcr.io/oss-fuzz-base/base-runner-testing-mybranch",
360344
"bash",
361345
"-c",
362-
"test_all.py || (echo \"********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture x86_64 skcms\npython infra/helper.py check_build --sanitizer address --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************\" && false)"
346+
"test_all.py || (echo "********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture x86_64 skcms\npython infra/helper.py check_build --sanitizer address --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************" && false)"
363347
],
364348
"id": "build-check-libfuzzer-address-x86_64"
365349
},
@@ -413,7 +397,7 @@
413397
"gcr.io/oss-fuzz/skcms",
414398
"bash",
415399
"-c",
416-
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/libfuzzer-address-i386 && compile || (echo \"********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture i386 skcms\n********************************************************************************\" && false)"
400+
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/libfuzzer-address-i386 && compile || (echo "********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture i386 skcms\n********************************************************************************" && false)"
417401
],
418402
"id": "compile-libfuzzer-address-i386"
419403
},
@@ -451,7 +435,7 @@
451435
"gcr.io/oss-fuzz-base/base-runner-testing-mybranch",
452436
"bash",
453437
"-c",
454-
"test_all.py || (echo \"********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture i386 skcms\npython infra/helper.py check_build --sanitizer address --engine libfuzzer --architecture i386 skcms\n********************************************************************************\" && false)"
438+
"test_all.py || (echo "********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer address --engine libfuzzer --architecture i386 skcms\npython infra/helper.py check_build --sanitizer address --engine libfuzzer --architecture i386 skcms\n********************************************************************************" && false)"
455439
],
456440
"id": "build-check-libfuzzer-address-i386"
457441
},
@@ -505,7 +489,7 @@
505489
"gcr.io/oss-fuzz/skcms",
506490
"bash",
507491
"-c",
508-
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/libfuzzer-undefined-x86_64 && compile || (echo \"********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer undefined --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************\" && false)"
492+
"rm -r /out && cd /src && cd skcms && mkdir -p /workspace/out/libfuzzer-undefined-x86_64 && compile || (echo "********************************************************************************\nFailed to build.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer undefined --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************" && false)"
509493
],
510494
"id": "compile-libfuzzer-undefined-x86_64"
511495
},
@@ -543,7 +527,7 @@
543527
"gcr.io/oss-fuzz-base/base-runner-testing-mybranch",
544528
"bash",
545529
"-c",
546-
"test_all.py || (echo \"********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer undefined --engine libfuzzer --architecture x86_64 skcms\npython infra/helper.py check_build --sanitizer undefined --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************\" && false)"
530+
"test_all.py || (echo "********************************************************************************\nBuild checks failed.\nTo reproduce, run:\npython infra/helper.py build_image skcms\npython infra/helper.py build_fuzzers --sanitizer undefined --engine libfuzzer --architecture x86_64 skcms\npython infra/helper.py check_build --sanitizer undefined --engine libfuzzer --architecture x86_64 skcms\n********************************************************************************" && false)"
547531
],
548532
"id": "build-check-libfuzzer-undefined-x86_64"
549533
},
@@ -563,4 +547,4 @@
563547
"targets_list > /workspace/targets.list.undefined"
564548
]
565549
}
566-
]
550+
]

0 commit comments

Comments
 (0)