[JIRA] (JENKINS-60129) Unable to automate configuration of permissions

3 views
Skip to first unread message

adamwdougal@gmail.com (JIRA)

unread,
Nov 11, 2019, 6:10:02 AM11/11/19
to jenkinsc...@googlegroups.com
Adam Dougal created an issue
 
Jenkins / Bug JENKINS-60129
Unable to automate configuration of permissions
Issue Type: Bug Bug
Assignee: Unassigned
Attachments: Screenshot 2019-11-11 at 11.07.38.png
Components: envinject-plugin
Created: 2019-11-11 11:09
Environment: Debian GNU/Linux 9
Jenkins 2.190.2
Env Inject Plugin 2.3.0
Configuration as Code Plugin 1.32
Role-based Authorization Strategy Plugin 2.15
Priority: Minor Minor
Reporter: Adam Dougal

I'm trying to automate the configuration of the `Enable permissions` EnvInject plugin setting.

 

I've tried using the Groovy code below: 

 

import org.jenkinsci.plugins.envinject.EnvInjectPluginConfiguration
EnvInjectPluginConfiguration config = GlobalConfiguration.all().get(EnvInjectPluginConfiguration.class) 
config.setEnablePermissions(true) 
config.save()

 

And the following configuration as code configuration:

 

security: 
   envinject: 
      hideInjectedVars: false
      enablePermissions: true 
      # Bad idea, see the security advisories 
      enableLoadingFromMaster: false

Both of which tick the `Enable permissions` checkbox on the `Configure Global Security` page.

 

However when I then go to manage roles I see the column title `Env. Inject` but no check boxes.

  

 

I've also tried using the configuration as code plugin to enable this permission but that doesn't seem to fix the issue either.

 

This has left me having to disable anyone from seeing environment variables to stop sensitive environment variables from being visible to anyone. Ideally I'd allow certain groups to see these to aid debugging.

 

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

o.v.nenashev@gmail.com (JIRA)

unread,
Nov 11, 2019, 7:32:03 AM11/11/19
to jenkinsc...@googlegroups.com
Oleg Nenashev updated an issue
Change By: Oleg Nenashev
Labels: jcasc-compatibility
Reply all
Reply to author
Forward
0 new messages