Bug 1712855 - BuildConfig env with value '${foo.bar}' fails build with Missing ':' in substitution: "${foo.bar}"
Summary: BuildConfig env with value '${foo.bar}' fails build with Missing ':' in subst...
Keywords:
Status: CLOSED DUPLICATE of bug 1712245
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Build
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Adam Kaplan
QA Contact: wewang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-05-22 11:26 UTC by Marek Schmidt
Modified: 2019-05-22 12:27 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-05-22 12:27:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Marek Schmidt 2019-05-22 11:26:36 UTC
Description of problem:

settings a BuildConfig env value to ${foo.bar} causes the build to fail in the LABEL step

oc set env bc/django-psql-example 'FOO=${foo.bar}'
oc start-build django-psql-example -F

STEP 1: FROM image-registry.openshift-image-registry.svc:5000/openshift/python@sha256:ae0c89a4319cba3ec689683a01dd80d825f37c89eeb92b88d59f84a71021c735 AS appimage7c42ee517c8311e9b63b0a580a83009d
STEP 2: LABEL "io.openshift.build.commit.ref"="master" "io.openshift.build.commit.message"="Merge pull request #137 from danmcp/patch-1" "io.openshift.build.source-location"="https://github.com/sclorg/django-ex.git" "io.openshift.build.image"="image-registry.openshift-image-registry.svc:5000/openshift/python@sha256:ae0c89a4319cba3ec689683a01dd80d825f37c89eeb92b88d59f84a71021c735" "io.openshift.build.commit.author"="Ben Parees <bparees.github.com>" "io.openshift.build.commit.date"="Wed Feb 20 10:40:10 2019 -0500" "io.openshift.build.commit.id"="090522300f6cfe9476308128684b1624e980df7b"
error: build error: error resolving step {Value:env Next:0xc4207fbab0 Children:[] Attributes:map[] Original:ENV OPENSHIFT_BUILD_NAME="django-psql-example-5" OPENSHIFT_BUILD_NAMESPACE="maschmod" OPENSHIFT_BUILD_SOURCE="https://github.com/sclorg/django-ex.git" OPENSHIFT_BUILD_COMMIT="090522300f6cfe9476308128684b1624e980df7b" PIP_INDEX_URL="" FOO="${foo.bar}" Flags:[] StartLine:3 endLine:3}: Missing ':' in substitution: "${foo.bar}"


Version-Release number of selected component (if applicable):
4.1.0-rc.5

How reproducible:
Always

Steps to Reproduce:
1. oc new-app django-psql-example
2. oc set env bc/django-psql-example 'FOO=${foo.bar}'
3. oc start-build django-psql-example -F

Actual results:

Build fails with 'Missing ':' in substitution: "${foo.bar}"'

Expected results:

Build should succeed, FOO env should be set literally to '${foo.bar}'

Additional info:

There should not be any attempt at substitution the env values as far as I know.

Regression since OCP 3.x, it used to be possible to set an env value to e.g. 'MAVEN_REPO_PRIVATE_KEY=${user.home}/.ssh/id_dsa'

Comment 1 Paul Weil 2019-05-22 12:27:54 UTC

*** This bug has been marked as a duplicate of bug 1712245 ***


Note You need to log in before you can comment on or make changes to this bug.