Open tanguydelignieresaccenture opened 4 years ago
actually we run into this aswell, we use a multilayer image and our build image needs two args (NPMRC credentials and NUGET credentials)
FYI, reproduced on debug-v1.3.0
Hi, I am a getting the same issue. Is this still relevant?
Ya, also getting this. Is the project dead?
Actual behavior Starting with
debug-v0.19.0
(reproduced withdebug-v1.0.0
), building using--cache=true
, a Dockerfile havingRUN
instruction withENV
orARG
variable and shell parameter expansion is not working anymore with the following error:error building image: error building stage: failed to optimize instructions: failed to process "RUN : \"${BINARY_NAME:?Build argument needs to be set and non-empty.}\"": unsupported modifier (?) in substitution
It might be related to #1085
With
debug-v0.18.0
, building using--cache=true
, a Dockerfile havingRUN
instruction withENV
orARG
variable and shell parameter expansion is working:(Do not pay attention to the
--registry-mirror
flag, it's only for dockerhub hostname resolution -- see #1209, nor the cache layer push error at the end, they do not prevent test the case or reproduce the issue)Expected behavior With >=
debug-v0.19.0
building using--cache=true
, a Dockerfile havingRUN
instruction withENV
orARG
variable and shell parameter expansion should still work as in <=debug-v0.18.0
.To Reproduce
RUN
instruction withENV
orARG
variable and shell parameter expansiondebug-v0.19.0
, with--cache=true
Additional Information
ENV BINARY_NAME=abinaryname
Check for mandatory build arguments
RUN : "${BINARY_NAME:?Build argument needs to be set and non-empty.}"