authentication - 在 Keycloak kubernetes helm 图表中设置新的扩展

标签 authentication kubernetes keycloak kubernetes-helm

我在 Azure 上有一个 Kubernetes 集群,我在其中使用 Helm 来更轻松地管理其上的微服务和其他工具,而 Keycloak 就是其中之一。

我需要在我的一个应用程序中使用魔术链接验证器,我知道我需要在我的 Keycloak 图表中添加一个扩展,但我不知道如何做。

图中repository我正在使用,他们解释了如何通过图表配置上的 extraInitContainers 参数添加自定义主题。我想我可以通过它实现我想要的。

在此tutorial他们说这是扩展,但我不知道如何使用 helm 图表将它添加到我在 k8s 上的 Keycloak 实例。我该如何实现?

关于我的配置的更多信息,我在一些我想保护的应用程序上运行 louketo-proxy(作为辅助工具)。

最佳答案

要发布带有原始图像的主题,首先 create an archive with the thema .

创建一个文件custom-themes-values.yml,内容如下:

extraInitContainers: |
  - name: theme-provider
    image: busybox
    imagePullPolicy: IfNotPresent
    command:
      - sh
    args:
      - -c
      - |
        echo "wgetting theme from maven..."
        wget -O /theme/keycloak-theme.jar  https://repo1.maven.org/maven2/org/acme/keycloak-theme/1.0.0/keycloak-theme-1.0.0.jar
    volumeMounts:
      - name: theme
        mountPath: /theme

extraVolumeMounts: |
  - name: theme
    mountPath: /opt/jboss/keycloak/standalone/deployments

extraVolumes: |
  - name: theme
    emptyDir: {}

运行:

helm install keycloak codecentric/keycloak --values custom-themes-values.yml

ps:本例主题发布到maven仓库,你可以拷贝一个本地文件到。

这样你就可以适应magic-link。

关于authentication - 在 Keycloak kubernetes helm 图表中设置新的扩展,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/63507672/

相关文章:

java - 获取 kubernetes Secret/env 以对 Java 应用程序进行身份验证

kubernetes - 通过TCP/UDP而不是Loadbalancer在外部公开服务

spring - 如何在 .html 文件中使用 Keycloak,将 thymleaf 与 spring security 一起使用?

c# - 自定义授权属性仅适用于本地主机

前端的Drupal自定义登录/注册

node.js - 如何在 Node.js 中重用 Play Framework 2.2 设置的签名 cookie?

symfony - 使用基本身份验证时如何识别用户?

maven - 如何使用臂架和Maven将镜像部署到kubernetes

Keycloak 一次性使用 token

java - 使用 quarkus-oidc 从 SecurityIdentity 访问用户信息