[JIRA] (JENKINS-59893) bat calls hang in Windows Docker container

4 views
Skip to first unread message

anonymousaccounts@icloud.com (JIRA)

unread,
Oct 22, 2019, 2:20:02 PM10/22/19
to jenkinsc...@googlegroups.com
a b created an issue
 
Jenkins / Bug JENKINS-59893
bat calls hang in Windows Docker container
Issue Type: Bug Bug
Assignee: Unassigned
Components: docker-workflow-plugin
Created: 2019-10-22 18:19
Labels: plugin jenkins docker-workflow-plugin docker
Priority: Minor Minor
Reporter: a b

Description

bat steps hang (endless spinning wheel in the jobs console output) even for simple Windows containers.

Troubleshooting & Additional info

powershell and all other commands tried so far work without issue. Even using powershell to wrap cmd.exe commands works fine. Example:

 

powershell "cmd /c echo test inside"

 

Running the image manually on the node host exhibits no issues. i.e. can run docker run -it microsoft/windowsservercore:ltsc2016 and happy use cmd and all other commands without issue.

Similarly we can attach to the container spun up by the Jenkins job while it's hung and execute the same echo command (or any other) without issue.

Others have not had this issue so it could be something specific in our setup, but I have not been able to pinpoint anything. https://github.com/jenkinsci/docker-workflow-plugin/pull/184#issuecomment-539213785

The job console output shows no errors and neither does the main Jenkins log under /log/all. No errors if any kind while the job is running / hung.

Setup

Jenkins node host: Windows Server 2016 (1607)

Docker image: microsoft/windowsservercore:ltsc2016

Happens regardless if docker {} or dockerfile {} syntax is used.

pipeline {
    agent {
        docker {
            image 'microsoft/windowsservercore:ltsc2016'
            label 'windows'
        }
    }
    stages {
        stage('Example Build') {
            steps{
                bat "echo test inside"
            }
        }
    }
}
Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

anonymousaccounts@icloud.com (JIRA)

unread,
Oct 22, 2019, 2:21:03 PM10/22/19
to jenkinsc...@googlegroups.com
a b updated an issue
Change By: a b
h3. Description


{{bat}} steps hang (endless spinning wheel in the jobs console output) even for simple Windows containers.

 
bat "echo test inside"
h3. Troubleshooting & Additional info


powershell and all other commands tried so far work without issue. Even using powershell to wrap cmd.exe commands works fine. Example:

 
{code:java}
powershell "cmd /c echo test inside"{code}

 

Running the image manually on the node host exhibits no issues. i.e. can run docker run -it microsoft/windowsservercore:ltsc2016 and happy use cmd and all other commands without issue.

Similarly we can attach to the container spun up by the Jenkins job while it's hung and execute the same echo command (or any other) without issue.

Others have not had this issue so it could be something specific in our setup, but I have not been able to pinpoint anything. [https://github.com/jenkinsci/docker-workflow-plugin/pull/184#issuecomment-539213785]

The job console output shows no errors and neither does the main Jenkins log under /log/all. No errors if any kind while the job is running / hung.
h3. Setup


Jenkins node host: {{Windows Server 2016 (1607)}}

Docker image: {{microsoft/windowsservercore:ltsc2016}}

Happens regardless if {{docker {}}} or {{dockerfile {}}} syntax is used.
{code:java}

pipeline {
    agent {
        docker {
            image 'microsoft/windowsservercore:ltsc2016'
            label 'windows'
        }
    }
    stages {
        stage('Example Build') {
            steps{
                bat "echo test inside"
            }
        }
    }
}{code}

anonymousaccounts@icloud.com (JIRA)

unread,
Oct 22, 2019, 2:21:03 PM10/22/19
to jenkinsc...@googlegroups.com

anonymousaccounts@icloud.com (JIRA)

unread,
Oct 22, 2019, 2:21:03 PM10/22/19
to jenkinsc...@googlegroups.com
a b updated an issue
h3. Description

{{bat}} steps hang (endless spinning wheel in the jobs console output) even for simple Windows containers.
{code:java}
Reply all
Reply to author
Forward
0 new messages