local config?
This commit is contained in:
parent
aab4521260
commit
c00c5a272e
3 changed files with 13 additions and 3 deletions
|
@ -21,7 +21,7 @@
|
|||
|
||||
(defn generate-config [my-config my-auth]
|
||||
(->
|
||||
(yaml/from-string (yaml/load-resource "config.yaml"))
|
||||
(yaml/from-string (yaml/load-resource "keycloak/config.yaml"))
|
||||
(assoc-in [:data :config.edn] (str my-config))
|
||||
(assoc-in [:data :credentials.edn] (str my-auth))))
|
||||
|
||||
|
|
11
src/main/resources/keycloak/config.yaml
Executable file
11
src/main/resources/keycloak/config.yaml
Executable file
|
@ -0,0 +1,11 @@
|
|||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: keycloak
|
||||
labels:
|
||||
app.kubernetes.io/name: k8s-keycloak
|
||||
data:
|
||||
config.edn: |
|
||||
some-config-value
|
||||
credentials.edn: |
|
||||
some-credentials-value
|
|
@ -2,8 +2,7 @@
|
|||
(:require
|
||||
#?(:clj [clojure.test :refer [deftest is are testing run-tests]]
|
||||
:cljs [cljs.test :refer-macros [deftest is are testing run-tests]])
|
||||
[dda.k8s-keycloak.core :as cut]
|
||||
[dda.k8s-keycloak.yaml :as yaml]))
|
||||
[dda.k8s-keycloak.core :as cut]))
|
||||
|
||||
(deftest should-generate-yaml
|
||||
(is (= {:apiVersion "v1", :kind "ConfigMap"
|
||||
|
|
Loading…
Reference in a new issue