• 使用Crowd集成Confluence与JIRA


     

    一. 独立安装Crowd,步骤1-步骤13的内容
    二. 设置Confluence使用Crowd进行认证。步骤14-18的内容
    三. 设置JIRA使用Crowd进行认证,并使用Confluence的组织机构数据,步骤19-步骤22的内容

    步骤:
    一.独立安装Crowd,步骤1-步骤12的内容

    解压缩atlassian-crowd-x.x.x.zip;

    2、在内嵌的Tomcat的apache-tomcatlib目录下放所需的数据库驱动,本文采用mysql;

    3、启动crowd,运行解压后目录中的start_crowd.bat,完成启动后,打开http://127.0.0.1:8095/crowd/console/;

    4、 此时,发现需要申请码。记下Server-ID,进行申请码的申请。

    5、配置数据库,在mysql中新建crowd的用户和表空间,输入

    • create user crowd identified by 'crowd';  
    • grant all privileges on *.* to 'crowd'@'%' identified by 'crowd' with grant option;  
    • grant all privileges on *.* to 'crowd'@'localhost' identified by 'crowd' with grant option;  
    • flush privileges; 

    6、破解

    7、填写申请码、按照默认项一路Next,设置Crowd server名称,Crowd上面有Home、Application、Principal、Group、Role、Session、Directory、Options、System Information、Backup & Restore等菜单。

    8、配置Directory,在Directory下选择Add Directory,选择Internal类型,名称填confluence。

    9、配置Uses:根据需要添加用户信息,设置Director为Crowd Server。并设置每个user的对应group。如需从已有的Jira或Conflucne中导入user,可选择import users进行导入,具体如下:选择Import Users,选择Atlassian Importer,配置Product,Directory,并将数据库参数填全,开始导入。

    10、配置Groups:在Groups菜单下面选择Add Group,增加以下组,与confluence和jira的组名对应

    confluence-administrators

    confluence-users

    jira-administrators

    jira-developers

    jira-users

    将用户配置到相应组中。

    11、 配置application:

    在Application下选择add application,分别增加confluence应用程序,设置Password(这里要记下,因为后面配置时还需要用),配置Directories为之前设置的Crowd server。配置Groups为confluence-administrators,confluence-users

    再次选择add application增加jira,配置Groups为jira-administrators,jira-developers,jira-users

    允许该Application中的Directory组均可登录该Applcation

    在“View Application – confluence”

    在Directories项里,选中Allow all to Authenticate为true,确认后选择update

    可以在Config Test中,测试登录。

    12、作完上述工作,Crowd的配置基本结束。

    二. 设置Confluence使用Crowd进行认证。步骤13-17
    13. 因采用的Confluence版本较新,其中已包含了crowd集成所需的jar包,采用管理员身份登陆confluence,配置
    14. 编辑confluence/WEB-INF/classes/crowd.properties
    application.name          confluence  设置的confluence访问帐号
    application.password   confluence  设置的confluence访问密码
    application.login.url     http://localhost:8095/crowd/console/

    crowd.server.url           http://localhost:8095/crowd/services/
    crowd.base.url             http://localhost:8095/crowd/

    session.isauthenticated session.isauthenticated
    session.tokenkey session.tokenkey
    session.validationinterval 2
    session.lastvalidation session.lastvalidation

    15.编辑CONFLUENCE/confluence/WEB-INF/classes/seraph-config.xml
    将如下配置进行注释:
    <!-- <authenticator class="com.atlassian.confluence.user.ConfluenceAuthenticator"/> -->
    取消如下注释:
    <authenticator class="com.atlassian.confluence.user.ConfluenceCrowdSSOAuthenticator"/>

    16.【可选】在Confluence系统管理>站点配置>安全隐私中打开Confluence的外部用户管理(External User Management),这样用户或管理员就不能在Confluence编辑用户信息了。也可以不做此项。

    17.通过以上步骤,已经将Confluence转移为使用Crowd进行认证了。可以重启Confluence服务后,访问进行测试一下。提示:需要通过在Confluence后台重建索引才能浏览到人员目录。

    三. 设置JIRA使用Crowd进行认证,并使用Confluence的组织机构数据,步骤14-步骤13的内容。
    下面是如何将JIRA配置成为使用Crowd服务以及Confluence的用户信息。

    18. 在jira中,使用管理员身份进入后,进入管理员页面下的用户管理-User Directories,点击Add Directory,选择Atlassian Crowd,输入Server Name,ServerURL为http://localhost:8095/crowd,Application Name为jira,password为之前设置的password。完成后Test Settings,并保存。
    调整Directory Name顺序将Crowd Server 移到首位。

    19. 类似步骤14。之前已经设置好了jira的所需group和app,在这里,只需配置访问方式即可。
    需要注意,本版本jira中JIRA/atlassian-jira/WEB-INF/classes/crowd.properties需要从confluence拷贝过来,修改相应app参数后即可使用。

    20.类似步骤15,编辑JIRA/atlassian-jira/WEB-INF/classes/seraph-config.xml,使之成为:
    取消此行的注释:
    <authenticator class="com.atlassian.jira.security.login.SSOSeraphAuthenticator"/>
    将此行注释:
    <!-- <authenticator class="com.atlassian.jira.security.login.JiraSeraphAuthenticator"/> -->

    21. 至此,所有单点登录配置已完成。重启jira服务器。可以试验下单点登录了,在同一个Session会话窗口中,登录其中一个应用成功后,可以发现已经自动登录到另外一个应用了。

  • 相关阅读:
    前端模板Nunjucks简介
    git提交时支持文件名大小写的修改
    多行文本加省略号的处理方法
    前端性能优化实践方案总结
    使用gulp工具生成svgsprites
    koa简介
    JSX语法简介
    踩坑所引发出的appendChild方法的介绍
    React业务实践
    javascript--数组
  • 原文地址:https://www.cnblogs.com/xxsl/p/6876941.html
Copyright © 2020-2023  润新知