Description of problem: BuildConfigs using Docker/Dockerfile strategy with FROM scratch causes a build failure: 'scratch' is a reserved name Version-Release number of selected component (if applicable): How reproducible: 100% Steps to Reproduce: 1. Use BuildConfig similar to https://github.com/bdecoste/jdv-jdg-sample/blob/master/datavirt63-jdg-s2i.json#L493 2. BuildConfig points to Dockerfile with 'FROM scratch' 3. Actual results: Failed build: 'scratch' is a reserved name Expected results: Successful build Additional info: Was looking at the OCP3.4 branch and it looks like the code you referenced that checks for the scratch image pre-pull is missing in OCP: https://github.com/openshift/ose/blob/enterprise-3.4/pkg/build/builder/docker.go#L97 https://github.com/openshift/origin/blob/master/pkg/build/builder/docker.go#L102-L120 Also looks like that code has changed significantly since 3.3
https://github.com/openshift/ose/pull/579
This has been merged into ocp and is in OCP v3.4.1.7 or newer.
Verified openshift v3.4.1.7 kubernetes v1.4.0+776c994 etcd 3.1.0-rc.0 # oc new-build -D $'FROM scratch\nENV NUM 1' --to=test # oc logs -f bc/test Step 1 : FROM scratch ---> Step 2 : ENV NUM 1 ---> Running in c67ed76f2559 ---> 328f24a22408 Removing intermediate container c67ed76f2559 Step 3 : ENV "OPENSHIFT_BUILD_NAME" "test-1" "OPENSHIFT_BUILD_NAMESPACE" "dyan1" ---> Running in ba4d1bf25a7a ---> 8bb37118587c Removing intermediate container ba4d1bf25a7a Successfully built 8bb37118587c
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2017:0289