question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Entry for Promotion/Promote authorizationMatrix is broken/doesn't work for building from casc

See original GitHub issue

Your checklist for this issue

🚨 Please review the Support Policy

  • The question was asked in the project’s Gitter chat
  • Jenkins version - 2.345-jdk11
  • Plugin version - Matrix Authorization Strategy 3.1.2 / Configuration as Code Plugin 1429.v09b_044a_c93de
  • OS - Ubuntu
  • Reproduction steps

Description

We’re using Matrix Authorization Strategy and configuration-as-code plugin to define an Authorization Matrix. For jobs that use promotion, there is a column in the matrix for Promotion/promote permission.

Screen Shot 2022-06-20 at 3 29 00 PM

Therefore, I added to my j2 template the following:

        - 'GROUP:Promotion/Promote:dev'
        - 'GROUP:Promotion/Promote:jenkins_editor'
        - 'GROUP:Promotion/Promote:staff'

However, jenkins wouldn’t build and gave this error:

Failed to parse 'GROUP:Promotion/Promote:dev' --- no such permission

So question, if Promotion/Promote isn’t right, what is? Or does this plugin not handle that permission? What should be my next steps?

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:12 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
pamgluss-slackcommented, Jun 27, 2022

The fix should be to apply the same as jenkinsci/jenkins#5723 to the permission in the corresponding plugin

i.e. force eager loading, before jcasc

@timja thank you for this! That was it, based on our testing!

Our colleague has a fix PR up if anyone in this thread is able to review: https://github.com/jenkinsci/promoted-builds-plugin/pull/208

0reactions
timjacommented, Jun 28, 2022

Thanks for the contribution, given this isn’t a bug in JCasC I’m going to close this issue at this point.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Jenkinsci Configuration-As-Code-Plugin Statistics & Issues
Entry for Promotion/Promote authorizationMatrix is broken/doesn't work for building from casc, closed, 12, 2022-06-20, 2022-09-26, 2022-06-28.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found