简体   繁体   English

在詹金斯中为用户实施安全性

[英]Implementing security for users in jenkins

I am after a better solution for security in Jenkins. 我正在寻求针对Jenkins的安全性更好的解决方案。 After my play around this space, my current solution is to implement the 'Project-based Matrix Authorization Strategy'. 在这个领域工作之后,我目前的解决方案是实施“基于项目的矩阵授权策略”。 I was previously considering running Jenkins behind Apache and control security through Apache. 我以前曾考虑在Apache后面运行Jenkins,并通过Apache控制安全性。 But during my trial with matrix based security, I was able to assign full access to logged in users and block anonymous users from seeing anything on the dashboard except login-page. 但是在进行基于矩阵安全性的试用期间,我能够为登录用户分配完全访问权限,并阻止匿名用户查看仪表板上除登录页面之外的任何内容。

Before I proceed with my beta servers, I would like to seek experts advice to understand what I am doing is correct ?or there is a better way to do this. 在继续使用Beta服务器之前,我想征询专家的意见,以了解我在做什么是正确的,或者有更好的方法来做到这一点。 At the moment I have around 30 users created in my system. 目前,我在系统中创建了大约30个用户。

If matrix based solution is the best and easiest, I would like to know, 1) Is it possible to group users and assign access based on groups ? 如果基于矩阵的解决方案是最好和最简单的,我想知道,1)是否可以对用户进行分组并根据组分配访问权限? So that I don't have to give users on individual basis 这样我就不必单独给用户

2) I also saw a post about 'Role strategy plug-in', but I couldn't see that in my Jenkins. 2)我还看到了有关“角色策略插件”的帖子,但在我的Jenkins中看不到。 Not sure if this plug-in out of date and/or nomore supported 不确定此插件是否过时和/或不再受支持

Thanks in advance. 提前致谢。

I'm using the Role Strategy plugin with a LDPA directory and it works well. 我正在将Role Strategy插件与LDPA目录一起使用,并且效果很好。

You just have to install this plugin on your Jenkins server and to switch from "Matrix-based security" to "Role-Based Strategy". 您只需要在Jenkins服务器上安装此插件,然后从“基于矩阵的安全性”切换到“基于角色的策略”即可。

Next, you will be able to define roles: 接下来,您将能够定义角色:

在此处输入图片说明

And assign them to users (or LDAP groups, if you have a LDAP directory): 并将它们分配给用户(或LDAP组,如果您有LDAP目录):

在此处输入图片说明

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM