[
https://issues.jenkins-ci.org/browse/JENKINS-13230?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=161668#comment-161668
]
gbois commented on JENKINS-13230:
---------------------------------
@bap
EnvInject variables are build process environment variables, jenkins variables
and build variables (parameterized, jenkins build variables, all contributions).
publih-over-ssh has to be aware of EnvInject with the following code.
* Get EnvInjetAction
EnvInjectActionRetriever#getEnvInjectAction(build)
* Get Environment variables in the EnvInjectAction
EnvInjectAction#getEnvMap()
* Use these variables to resolve your values
> Not able to use Jenkins Environment Variables and variables injected through
> Env Inject plugin when executing commands over ssh in Publish over SSH plugin
> ----------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: JENKINS-13230
> URL: https://issues.jenkins-ci.org/browse/JENKINS-13230
> Project: Jenkins
> Issue Type: Bug
> Components: publish-over-ssh
> Affects Versions: current
> Environment: RHEL 5.5
> Reporter: suresh kukalakuntla
> Assignee: bap
>
> I am trying to use Jenkins environment variables and variables injected
> through Env Inject plugin in Execute section of 'Send build artifacts over
> SSH'. It does not recognize them. It does recognize the build parameters and
> replaces them with the values. When I look at the 'Injected environment
> variables' I see all the variables I want to use. Not sure if I have to do
> anything different to be able to use those variables.
> In Job configuration I checked 'Prepare an environment for the run' and 'Keep
> Jenkins Environment Variables', 'Keep Jenkins Build Variables'.
> I have an 'Evaluated Groovy script' that sets 'MODULE_HOME' based on build
> time parameter MODULE_NAME.
> Please let me know how to proceed.
--
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