[JIRA] (JENKINS-44930) Allow sh to return exit status, stdout and stderr all at once
Title: Message Title JD Friedrikson edited a comment on JENKINS-44930 Re: Allow sh to return exit status, stdout and stderr all at once Just sharing my workaround for others:{code:groovy}pipeline { agent {docker { image 'debian'} } stages {stage('script') { steps {script { status = sh(returnStatus: true,script: '''#!/bin/bash exec > >(tee output.log) 2>&1 echo 'one: stdout' >&2 echo 'one: stderr' exit 1''' ) output = readFile('output.log').trim() echo output if (status != 0) {currentBuild.result = 'UNSTABLE' }} }} } post {cleanup { deleteDir()} }}{code} { panel code:text }[Pipeline] {[Pipeline] stage[Pipeline] { (script)[Pipeline] script[Pipeline] {[Pipeline] shone: stdoutone: stderr[Pipeline] readFile[Pipeline] echoone: stdoutone: stderr[Pipeline] }[Pipeline] // script[Pipeline] }[Pipeline] // stage[Pipeline] stage[Pipeline] { (Declarative: Post Actions)[Pipeline] deleteDir (show)[Pipeline] }[Pipeline] // stage[Pipeline] }[Pipeline] // withDockerContainer[Pipeline] }[Pipeline] // node[Pipeline] End of PipelineFinished: UNSTABLE{ panel code } Add Comment This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] (JENKINS-44930) Allow sh to return exit status, stdout and stderr all at once
Title: Message Title JD Friedrikson edited a comment on JENKINS-44930 Re: Allow sh to return exit status, stdout and stderr all at once Just sharing my workaround for others:{code:groovy}pipeline { agent {docker { image 'debian'} } stages {stage('script') { steps {script { status = sh(returnStatus: true,script: '''#!/bin/bash exec > >(tee output.log) 2>&1 echo 'one: stdout' >&2 echo 'one: stderr' exit 1''' ) output = readFile('output.log').trim() echo output if (status != 0) {currentBuild.result = 'UNSTABLE' }} }} } post {cleanup { deleteDir()} }}{code}{code :text }[Pipeline] {[Pipeline] stage[Pipeline] { (script)[Pipeline] script[Pipeline] {[Pipeline] shone: stdoutone: stderr[Pipeline] readFile[Pipeline] echoone: stdoutone: stderr[Pipeline] }[Pipeline] // script[Pipeline] }[Pipeline] // stage[Pipeline] stage[Pipeline] { (Declarative: Post Actions)[Pipeline] deleteDir (show)[Pipeline] }[Pipeline] // stage[Pipeline] }[Pipeline] // withDockerContainer[Pipeline] }[Pipeline] // node[Pipeline] End of PipelineFinished: UNSTABLE{code} Add Comment This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] (JENKINS-44930) Allow sh to return exit status, stdout and stderr all at once
Title: Message Title JD Friedrikson commented on JENKINS-44930 Re: Allow sh to return exit status, stdout and stderr all at once Just sharing my workaround for others: pipeline { agent { docker { image 'debian' } } stages { stage('script') { steps { script { status = sh( returnStatus: true, script: '''#!/bin/bash exec > >(tee output.log) 2>&1 echo 'one: stdout' >&2 echo 'one: stderr' exit 1 ''' ) output = readFile('output.log').trim() echo output if (status != 0) { currentBuild.result = 'UNSTABLE' } } } } } post { cleanup { deleteDir() } } } [Pipeline] { [Pipeline] stage [Pipeline] { (script) [Pipeline] script [Pipeline] Unknown macro: { [Pipeline] sh one} [Pipeline] // script [Pipeline] } [Pipeline] // stage [Pipeline] stage [Pipeline] Unknown macro: { (Declarative} [Pipeline] // stage [Pipeline] } [Pipeline] // withDockerContainer [Pipeline] } [Pipeline] // node [Pipeline] End of Pipeline Finished: UNSTABLE Add Comment
[JIRA] (JENKINS-56784) Store console output in S3
Title: Message Title JD Friedrikson created an issue Jenkins / JENKINS-56784 Store console output in S3 Issue Type: Improvement Assignee: Unassigned Components: artifact-manager-s3-plugin Created: 2019-03-27 19:39 Priority: Minor Reporter: JD Friedrikson Currently, it seems that only artifacts are being stored in S3 while the console output is being stored on disk. Given that output for some builds can be quite sizable, I think it would be useful to have the option of also storing console output in S3. Add Comment
[JIRA] (JENKINS-56782) EBS encryption support
Title: Message Title JD Friedrikson created an issue Jenkins / JENKINS-56782 EBS encryption support Issue Type: Improvement Assignee: FABRIZIO MANFREDI Components: ec2-plugin Created: 2019-03-27 15:48 Priority: Minor Reporter: JD Friedrikson Cloud templates for the EC2 should include a field to enable disk encryption for EBS volumes. Currently, it seems to be unencrypted without any option to specify otherwise. For builds that include sensitive information, this is a must. Add Comment This
[JIRA] (JENKINS-54186) No @DataBoundConstructor on any constructor of class jenkins.plugins.git.GitSCMSourceDefaults
Title: Message Title JD Friedrikson commented on JENKINS-54186 Re: No @DataBoundConstructor on any constructor of class jenkins.plugins.git.GitSCMSourceDefaults This will keep you from seeing other CPS-related warnings. Add Comment This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.