jenkinsci / jenkinsci/docker-workflow-plugin

[JENKINS-66605] Declarative pipeline with Docker image overrides PATH inside container on Windows

Open
#675 4 comments 0 reactions 0 assignees View on GitHub
agent component:docker-workflow-plugin imported-jira-issue priority:blocker resolution:unresolved
Dominant language
Java
Stars
527
Forks
422
Avg merge
10m
Merged PRs (30d)
1

Description

It shouldn't override container PATH.

My pipeline

pipeline {

agent none

stages {
stage('app02') {
agent {
docker {
label "app02"
image "ghcr.visualon.de/visualon/builder"
}
}
steps {
bat 'set'
bat 'msbuild -version'
}
}
stage('docker-d03') {
agent {
docker {
label "docker-d03"
image "ghcr.visualon.de/visualon/builder"
}
}
steps {
bat 'set'
bat 'msbuild -version'
}
}
}
}

---
Originally reported by viceice, imported from: Declarative pipeline with Docker image overrides PATH inside container on Windows


  • status: Open
  • priority: Blocker
  • component(s): docker-workflow-plugin
  • label(s): docker-slaves, docker-workflow-plugin, slave, windows
  • resolution: Unresolved
  • votes: 0
  • watchers: 1
  • imported: 2025-12-07

Raw content of original issue

It shouldn't override container PATH.

My pipeline


pipeline {

agent none

stages {
stage('app02') {
agent {
docker {
label "app02"
image "ghcr.visualon.de/visualon/builder"
}
}
steps {
bat 'set'
bat 'msbuild -version'
}
}
stage('docker-d03') {
agent {
docker {
label "docker-d03"
image "ghcr.visualon.de/visualon/builder"
}
}
steps {
bat 'set'
bat 'msbuild -version'
}
}
}
}

environment

```
Windows Server 2019 / 2022 SSH slaves with Java 11

Jenkins LTS 2.303.1 running in Kubernetes

Latest plugin versions
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.