jenkinsci / jenkinsci/agent-setup-plugin
[JENKINS-56081] Slave node environment path is duplicated
- Dominant language
- Java
- Stars
- 11
- Forks
- 23
- Avg merge
- 21h 13m
- Merged PRs (30d)
- 1
Description
When running a slave with the path set in environment variables the (added) path is duplicated.
Steps
- Created a slave to run on localhost by Java Web Start.
- Add node properties environment variables, name: Path value: $Path;X;Y;Z
- Run pipeline job that displays the path
Expected
To see the path ending with ;X;Y;Z
Actual
The path ends with :X;Y;Z;X;Y;Z
pipeline {
agent {
label 'slave-1'
}
stages {
stage('path') {
steps {
bat('path')
}
} //stage
} //stages
} //pipeline
---
Originally reported by
wibek, imported from: Slave node environment path is duplicated
peppe
Raw content of original issue
When running a slave with the path set in environment variables the (added) path is duplicated.
Steps
- Created a slave to run on localhost by Java Web Start.
- Add node properties environment variables, name: Path value: $Path;X;Y;Z
- Run pipeline job that displays the path
Expected
To see the path ending with ;X;Y;Z
Actual
The path ends with :X;Y;Z;X;Y;Z
pipeline {
agent {
label 'slave-1'
}
stages {
stage('path') {
steps {
bat('path')
}
} //stage
} //stages
} //pipeline
environment
```
Jenkins ver. 2.150.2
Windows 10 pro
Environment injector plugin 2.1.6
```
Contributor guide
Assessment
This issue has not been assessed yet.