簡體   English   中英

在 Keycloak kube.netes helm 圖表中設置新的擴展

[英]Set up new extensions in Keycloak kubernetes helm charts

我在 Azure 上有一個 Kube.netes 集群,我在其中使用 Helm 來更輕松地管理其上的微服務和其他工具,而 Keycloak 就是其中之一。

我需要在我的一個應用程序中使用魔術鏈接驗證器,我知道我需要在我的 Keycloak 圖表中添加一個擴展,但我不知道如何。

在我使用的圖像存儲庫中,他們解釋了如何通過圖表配置上的extraInitContainers參數添加自定義主題。 我想我可以通過它實現我想要的。

在本教程中,他們說這是擴展,但我不知道如何使用 helm 圖表將它添加到我在 k8s 上的 Keycloak 實例。 我如何做到這一點?

關於我的配置的更多信息,我在一些我想要保護的應用程序上運行 louketo-proxy(作為邊車)。

要發布帶有原始圖像的主題,首先使用 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。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM