The following plugin provides functionality available through Pipeline-compatible steps. Read more about how to integrate steps into your Pipeline in the Steps section of the Pipeline Syntax page.

For a list of other such plugins, see the Pipeline Steps Reference page.

Role-based Authorization Strategy

currentUserGlobalRoles: Current Users Global Roles

Returns a list of all global roles of the user that started the build. This includes roles assigned via groups. When the run is triggered by an SCM event or by the timer, the build usually runs as the System user. This user is considered as having all roles.
You can use the Authorize Project plugin to run the builds as a different user. When running as anonymous, an empty list is returned.

    currentUserItemRoles: Current Users Item Roles

    Returns a list of all item roles of the user that started the build. This includes roles assigned via groups. When the run is triggered by an SCM event or by the timer, the build usually runs as the System user. This user is considered as having all roles.
    You can use the Authorize Project plugin to run the builds as a different user. When running as anonymous, an empty list is returned.
    • showAllRoles : boolean (optional)
      If checked, all item roles of the user are returned. Otherwise only roles matching the pipeline job are returned.

    Was this page helpful?

    Please submit your feedback about this page through this quick form.

    Alternatively, if you don't wish to complete the quick form, you can simply indicate if you found this page helpful?

        


    See existing feedback here.