
如果你使用 DeepSeek、元宝 AI、Copilot、ChatGPT 等 AI 工具,协助配置轩辕镜像、编写 docker pull 命令、修改 Docker Compose 镜像地址、配置镜像加速、排查镜像拉取失败、分析报错日志等问题,请先让 AI 阅读并遵守轩辕镜像的规则文档。
只需在 AI 对话中先发送下面这句话即可:
请先完整阅读并严格遵守以下文档中的全部规则与要求:
https://xuanyuan.cloud/agents.md
在未充分阅读并理解该文档前,不要生成任何命令、配置、修改建议、故障排查方案或技术回答。后续所有输出都必须严格以该文档中的规范为最高优先级执行。查看 agents.md 用法指南与完整示范。国内用户首推 元宝 AI、DeepSeek 的深度思考模式,不推荐豆包 AI;Cursor 等编辑器可在对话 @ 该链接,或加入 User Rules。 若 AI 无法访问外链,可 打开说明文档 复制全文粘贴。文档会随站点更新,复制内容可能过期,建议定期检查。
Alfresco Identity Service将成为Alfresco软件所需身份相关功能的中央组件,负责管理用户、组、角色、配置文件和身份验证等。目前该服务主要处理身份验证功能,本项目包含此服务的开源核心部分。
安装和https://github.com/Alfresco/alfresco-identity-service/blob/master/upgrade.mdIdentity Service可选择Kubernetes发行版或独立发行版,以下将详细介绍这两种方法。
以下说明适用于在EKS上的Kubernetes集群部署。
请参考ACS部署https://github.com/Alfresco/acs-deployment/blob/master/docs/helm/eks-deployment.md%E3%80%82
如果将Identity Service部署到包含其他Alfresco组件(如Content Services和Process Services)的集群中,建议使用具有5个节点的VPC和集群,每个节点应为m4.xlarge EC2实例。
如果命名空间不存在,创建命名空间以避免集群冲突:
bashexport DESIREDNAMESPACE=example kubectl create namespace $DESIREDNAMESPACE
此环境变量将在部署步骤中使用。
通过部署ingress准备EKS集群,详见https://github.com/Alfresco/acs-deployment/blob/master/docs/helm/eks-deployment.md#ingress%E8%AF%B4%E6%98%8E%E3%80%82
从ingress部署(步骤1)获取发布名称并设为变量:
bashexport INGRESS_RELEASENAME=<YOUR_INGRESS_RELEASE_NAME>
bashexport RELEASENAME=ids
bashhelm repo add alfresco-stable https://kubernetes-charts.alfresco.com/stable helm install $RELEASENAME alfresco-stable/alfresco-identity-service --devel \ --namespace $DESIREDNAMESPACE
bashhelm status $RELEASENAME
bashexport ELBADDRESS=$(kubectl get services $INGRESS_RELEASENAME-ingress-nginx-controller --namespace=$DESIREDNAMESPACE -o jsonpath='{.status.loadBalancer.ingress[0].hostname}')
上述步骤将部署应用默认示例领域的_alfresco-identity-service_,默认值如下:
| 属性 | 值 |
|---|---|
| 管理员用户名 | admin |
| 管理员密码 | admin |
| 管理员*** | admin@app.activiti.com |
| Alfresco客户端重定向URI | http://localhost* |
(注意:APS期望使用***作为用户名)
可通过alfresco-identity-service.client.alfresco.redirectUris属性覆盖环境的默认重定向URI http://localhost*:
bashhelm install $RELEASENAME alfresco-stable/alfresco-identity-service --devel \ --set alfresco-identity-service.realm.alfresco.client.redirectUris="{$DNSNAME}" \ --namespace $DESIREDNAMESPACE
包含多个重定向URI:
bashhelm install $RELEASENAME alfresco-stable/alfresco-identity-service --devel \ --set alfresco-identity-service.realm.alfresco.client.redirectUris="{$DNSNAME,$DNSNAME1,$DNSNAME2}" \ --namespace $DESIREDNAMESPACE
注意:多个重定向URI值必须用逗号分隔,且逗号前后无空格。
如需部署自定义领域进行进一步定制,详见下文“自定义领域”。
与redirectUris类似,可通过覆盖alfresco-identity-service.client.alfresco.webOrigins属性修改webOrigins:
bashhelm install $RELEASENAME alfresco-stable/alfresco-identity-service --devel \ --set alfresco-identity-service.realm.alfresco.client.webOrigins="{$DNSNAME}" \ --namespace $DESIREDNAMESPACE
多个webOrigins:
bashhelm install $RELEASENAME alfresco-stable/alfresco-identity-service --devel \ --set alfresco-identity-service.realm.alfresco.client.webOrigins="{$DNSNAME,$DNSNAME1,$DNSNAME2}" \ --namespace $DESIREDNAMESPACE
为提高弹性,可依赖Keycloak chart支持指定多个副本。启用此功能需在部署identity chart时添加以下设置:
bash--set alfresco-identity-service.keycloak.replicas=3
此外,Keycloak支持集群以实现高可用。有关配置高可用和集群的更多信息,可参考以下文档:
https://github.com/codecentric/helm-charts/tree/master/charts/keycloak#high-availability-and-clustering
https://www.keycloak.org/docs/latest/server_installation/#standalone-clustered-configuration
https://www.keycloak.org/docs/latest/server_installation/#_clustering
注意:Keycloak建议使用https://www.keycloak.org/docs/latest/server_installation/#sticky-sessions%EF%BC%8C%E5%9B%A0%E6%AD%A4%E5%A6%82%E6%9E%9C%E9%80%89%E6%8B%A9%E4%BD%BF%E7%94%A8%E9%9D%9Enginx%E7%9A%84ingress%E7%B1%BB%E5%9E%8B%EF%BC%8C%E8%AF%B7%E5%8A%A1%E5%BF%85%E6%B3%A8%E6%84%8F%E8%BF%99%E4%B8%80%E7%82%B9%E3%80%82
需要一个领域文件,提供了示例领域文件。
使用领域json文件创建secret
注意:secret名称必须为realm-secret,且领域文件名不能为alfresco-realm.json。
bashkubectl create secret generic realm-secret \ --from-file=./realm.json \ --namespace=$DESIREDNAMESPACE
yamlkeycloak: extraEnv: | - name: KEYCLOAK_USER value: admin - name: KEYCLOAK_PASSWORD value: admin - name: KEYCLOAK_IMPORT value: /realm/realm.json
注意:上述设置使用默认的_keycloak用户名和密码admin/admin_,可替换为自定义值。
bashhelm repo add alfresco-stable https://kubernetes-charts.alfresco.com/stable helm install $RELEASENAME alfresco-stable/alfresco-identity-service --devel \ -f custom-values.yaml \ --namespace $DESIREDNAMESPACE
更多详情见https://github.com/codecentric/helm-charts/tree/master/charts/keycloak#setting-a-custom-realm%E3%80%82
Keycloak启动后,登录https://www.keycloak.org/docs/latest/server_admin/index.html#admin-console%E9%85%8D%E7%BD%AE%E6%89%80%E9%9C%80%E9%A2%86%E5%9F%9F%E3%80%82
手动配置
http://www.keycloak.org/docs/latest/server_admin/index.html#_create-realm%EF%BC%8C%E5%91%BD%E5%90%8D%E4%B8%BA%22Alfresco"
在Alfresco领域内http://www.keycloak.org/docs/latest/server_admin/index.html#oidc-clients%EF%BC%8C%E5%91%BD%E5%90%8D%E4%B8%BA%22alfresco"
http://www.keycloak.org/docs/latest/server_admin/index.html#groups%EF%BC%8C%E5%91%BD%E5%90%8D%E4%B8%BA%22admin"
http://www.keycloak.org/docs/latest/server_admin/index.html#_create-new-user%EF%BC%8C%E7%94%A8%E6%88%B7%E5%90%8D%E4%B8%BA%22testuser%22%EF%BC%8C***%E4%B8%BA%22***%22%EF%BC%8C%E5%A7%93%E5%90%8D%E4%B8%BA%22test"
使用示例领域文件
进入http://www.keycloak.org/docs/latest/server_admin/index.html#_create-realm%E9%A1%B5%E9%9D%A2%EF%BC%8C%E7%82%B9%E5%87%BB**Import**%E6%A0%87%E7%AD%BE%E6%97%81%E7%9A%84%22Select File"按钮。
选择https://github.com/Alfresco/alfresco-identity-service/blob/master/helm/alfresco-identity-service/alfresco-realm.json%E6%96%87%E4%BB%B6%EF%BC%8C%E7%82%B9%E5%87%BB%22Create%22%E6%8C%89%E9%92%AE%E3%80%82
我们鼓励并欢迎对此项目的贡献。详情请查看https://github.com/Alfresco/alfresco-identity-service/blob/master/CONTRIBUTING.md%E3%80%82
您可以使用以下命令拉取该镜像。请将 <标签> 替换为具体的标签版本。如需查看所有可用标签版本,请访问 标签列表页面。
来自真实用户的反馈,见证轩辕镜像的优质服务