Adam Bien's Weblog

Accessing The Current Build User In Jenkinsfile Pipeline

To access the current user in the Jenkinsfile install the Build User Vars Plugin first. After the installation the current user becomes available within the wrap block:


 wrap([$class: 'BuildUser']) {
    echo "userId=${BUILD_USER_ID},fullName=${BUILD_USER},email=${BUILD_USER_EMAIL}"
}

See you at Java EE Workshops at MUC Airport, particularly at the Java EE Testing, Pipelines as Code, CI / CD, Testing and Quality workshop


NEW online workshop: WebStandards Igniter (online)

Airport MUC workshops: Java EE 7: Bootstrap, Effective, Architectures, Web, React and Angular, Testing and Microservices

Newsletter: airhacks.news

A book about rethinking Java EE Patterns

Comments:

Post a Comment:
  • HTML Syntax: NOT allowed
realworldpatterns.com
Online Workshops
...the last 150 posts
...the last 10 comments
License