[
https://issues.jenkins-ci.org/browse/JENKINS-14006?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=163722#comment-163722
]
Gabriele Giuseppini commented on JENKINS-14006:
-----------------------------------------------
Attaching the anonymized job config. Unfortunately, the rest of the folder
contains a lot of sensitive information. I will provide specific files on
demand if really needed.
> EnvInject stopped resolving environment variables in environment variables
> --------------------------------------------------------------------------
>
> Key: JENKINS-14006
> URL: https://issues.jenkins-ci.org/browse/JENKINS-14006
> Project: Jenkins
> Issue Type: Bug
> Components: envinject
> Environment: Jenkins 1.463, EnvInject 1.54 or 1.50
> Reporter: Gabriele Giuseppini
> Assignee: Gregory Boissinot
> Attachments: config.xml, config.xml
>
>
> This looks like an exact regression to JENKINS-13183.
> We have a Promotion job that injects an env var whose value contains
> references to other env vars, read from a properties file:
> {code:xml}
> <buildSteps>
> <EnvInjectBuilder>
> <info>
> <propertiesFilePath>StageCraft.properties</propertiesFilePath>
>
> <propertiesContent>ReleaseDir=${ReleaseRoot}\${PROJECT_NAME}\${PROJECT_NAME}_${PROJECT_SHORT_VERSION}
> ReleaseDirTest=${env['PROJECT_SHORT_VERSION']}
> </propertiesContent>
> </info>
> </EnvInjectBuilder>
> {code}
> (note we added a 'ReleaseDirTest' env var to also try the alternate env var
> reference syntax).
> EnvInject used to be fine with this, but after we did a few upgrades (to
> Jenkins itself and to the EnvInject plugin), it stopped working. Here's the
> output, together with a dump of the env vars injected in the build steps for
> diagnostics purposes:
> {code}
> Promoting ANONYMIZED #6
> [EnvInject] - Injecting environment variables from a build step.
> [EnvInject] - Injecting as environment variables the properties file path
> 'StageCraft.properties'
> [EnvInject] - Variables injected successfully.
> [EnvInject] - Injecting as environment variables the properties content
> ReleaseDir=${ReleaseRoot}\${PROJECT_NAME}\${PROJECT_NAME}_${PROJECT_SHORT_VERSION}
> ReleaseDirTest=${env['PROJECT_SHORT_VERSION']}
> [EnvInject] - Variables injected successfully.
> [EnvInject] - Unset unresolved 'ReleaseDir' variable.
> [EnvInject] - Unset unresolved 'ReleaseDirTest' variable.
> build org.jenkinsci.plugins.envinject.EnvInjectBuilder@53c01def SUCCESS
> [workspace] $ cmd /c call
> C:\Users\svc_ci\AppData\Local\Temp\hudson1186946183352599382.bat
> C:\jenkins\jobs\ANONYMIZED\workspace>SET
> ALLUSERSPROFILE=C:\ProgramData
> ...
> ProgramW6432=C:\Program Files
> PROJECT_FULL_VERSION=1.6.0.7
> PROJECT_NAME=ANONYMIZED
> PROJECT_SHORT_VERSION=1.6.0
> PROMOTED_ID=2012-06-01_15-42-27
> ...
> C:\jenkins\jobs\Cupid_1.6.x\workspace>exit 0
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira