[JIRA] (JENKINS-58777) sh step stuck on when adding inheritFrom in the kubernetes agent section

6 views
Skip to first unread message

hanbingxin49@gmail.com (JIRA)

unread,
Aug 2, 2019, 1:39:03 AM8/2/19
to jenkinsc...@googlegroups.com
jubel han created an issue
 
Jenkins / Bug JENKINS-58777
sh step stuck on when adding inheritFrom in the kubernetes agent section
Issue Type: Bug Bug
Assignee: Carlos Sanchez
Components: kubernetes-plugin
Created: 2019-08-02 05:38
Environment: kubernetes-plugin:1.18.0
Labels: kubernetes-plugin
Priority: Major Major
Reporter: jubel han

After upgraded the kubernetes-plugin to 1.18.0, all of my pipelines hanging on in the one of shell step, and it ended up with the following error.

process apparently never started in /home/jenkins/workspace/playaround@tmp/durable-3833ccbe
 (running Jenkins temporarily with -Dorg.jenkinsci.plugins.durabletask.BourneShellScript.LAUNCH_DIAGNOSTICS=true might make the problem clearer)

After a deep investigation, I've reproduced the issue with the following minimal pipeline code.

pipeline {
    agent {
        kubernetes {
            label 'playaround'
            containerTemplate(name: 'busybox', image: 'busybox', command: 'cat', ttyEnabled: true)
            inheritFrom 'default'
        }
    }
    
    stages {
        stage('debug') {
            steps {
                sh "echo in steps"

                script {
                    sh "echo in script"

                    container('busybox') {

                        sh "echo in busybox container"
                    }
                }
            }
        }
    }
}

t hanging on in the last sh step inside of the `busybox` container.
and it works if I using the default `jnlp` container or by removing the `inheritFrom` from agent definition.

This is a major issue for running the pipelines using kubernetes plugin.

as the workaround, I've rollback to the version `1.17.3`, all works.

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)

hanbingxin49@gmail.com (JIRA)

unread,
Aug 2, 2019, 1:40:03 AM8/2/19
to jenkinsc...@googlegroups.com
jubel han updated an issue
Change By: jubel han
After upgraded the kubernetes-plugin to 1.18.0, all of my pipelines hanging on in the one of shell step, and it ended up with the following error.
{code:java}

process apparently never started in /home/jenkins/workspace/playaround@tmp/durable-3833ccbe
(running Jenkins temporarily with -Dorg.jenkinsci.plugins.durabletask.BourneShellScript.LAUNCH_DIAGNOSTICS=true might make the problem clearer)
{code}

After a deep investigation, I've reproduced the issue with the following minimal pipeline code.
{code:java}

pipeline {
    agent {
        kubernetes {
            label 'playaround'
            containerTemplate(name: 'busybox', image: 'busybox', command: 'cat', ttyEnabled: true)
            inheritFrom 'default'
        }
    }
    
    stages {
        stage('debug') {
            steps {
                sh "echo in steps"

                script {
                    sh "echo in script"

                    container('busybox') {

                     sh "echo in busybox container"
                    }
                }
            }
        }
    }
}
{code}
t It hanging on in the last sh step inside of the `busybox` container.

and it works if I using the default `jnlp` container or by removing the `inheritFrom` from agent definition.

This is a major issue for running the pipelines using kubernetes plugin.

as the workaround, I've rollback to the version `1.17.3`, all works.

vincent@latombe.net (JIRA)

unread,
Aug 2, 2019, 8:49:03 AM8/2/19
to jenkinsc...@googlegroups.com

vincent@latombe.net (JIRA)

unread,
Aug 2, 2019, 10:21:01 AM8/2/19
to jenkinsc...@googlegroups.com
Vincent Latombe closed an issue as Duplicate
 
Change By: Vincent Latombe
Status: Open Closed
Resolution: Duplicate
Reply all
Reply to author
Forward
0 new messages