Skip to content

Commit

Permalink
Merge pull request #155 from projectsyn/rename-db-certs-path
Browse files Browse the repository at this point in the history
Rename database certificate directory to /opt/keycloak/db-certs
  • Loading branch information
megian authored Jul 22, 2022
2 parents 289b65a + fe2460d commit 26b94a3
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions class/defaults.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ parameters:
password: "?{vaultkv:${cluster:tenant}/${cluster:name}/${_instance}/db-password}"
database: keycloak
username: keycloak
jdbcParams: sslmode=verify-ca&sslrootcert=/opt/jboss/certs/tls.crt
jdbcParams: sslmode=verify-ca&sslrootcert=/opt/keycloak/db-certs/tls.crt

tls:
enabled: true
Expand Down Expand Up @@ -212,7 +212,7 @@ parameters:
extraVolumeMounts: |
- name: db-certs
readOnly: true
mountPath: /opt/jboss/certs
mountPath: /opt/keycloak/db-certs
- name: keycloak-tls
readOnly: true
mountPath: /etc/x509/https
Expand Down
4 changes: 2 additions & 2 deletions docs/modules/ROOT/pages/references/parameters.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -541,10 +541,10 @@ default:: `keycloak`

[horizontal]
type:: string
default:: `sslmode=verify-ca&sslrootcert=/opt/jboss/certs/tls.crt`
default:: `sslmode=verify-ca&sslrootcert=/opt/keycloak/db-certs/tls.crt`

Please note that if you need to customize JDBC parameters, copy and append them to the default with `&`, otherwise TLS will be disabled.
For example: `sslmode=verify-ca&sslrootcert=/opt/jboss/certs/tls.crt&mycustomparameter=somevalue`
For example: `sslmode=verify-ca&sslrootcert=/opt/keycloak/db-certs/tls.crt&mycustomparameter=somevalue`


== `database.password`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ spec:
periodSeconds: 5
timeoutSeconds: 1
volumeMounts:
- mountPath: /opt/jboss/certs
- mountPath: /opt/keycloak/db-certs
name: db-certs
readOnly: true
- mountPath: /etc/x509/https
Expand Down
2 changes: 1 addition & 1 deletion tests/golden/builtin/builtin/builtin/11_db_secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ metadata:
name: keycloak-postgresql
name: keycloak-postgresql
stringData:
JDBC_PARAMS: sslmode=verify-ca&sslrootcert=/opt/jboss/certs/tls.crt
JDBC_PARAMS: sslmode=verify-ca&sslrootcert=/opt/keycloak/db-certs/tls.crt
KC_DB_PASSWORD: t-silent-test-1234/c-green-test-1234/builtin/db-password
postgresql-password: t-silent-test-1234/c-green-test-1234/builtin/db-password
postgresql-postgres-password: t-silent-test-1234/c-green-test-1234/builtin/db-password
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ spec:
periodSeconds: 5
timeoutSeconds: 1
volumeMounts:
- mountPath: /opt/jboss/certs
- mountPath: /opt/keycloak/db-certs
name: db-certs
readOnly: true
- mountPath: /etc/x509/https
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ spec:
periodSeconds: 5
timeoutSeconds: 1
volumeMounts:
- mountPath: /opt/jboss/certs
- mountPath: /opt/keycloak/db-certs
name: db-certs
readOnly: true
- mountPath: /etc/x509/https
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ metadata:
name: keycloak-postgresql
name: keycloak-postgresql
stringData:
JDBC_PARAMS: sslmode=verify-ca&sslrootcert=/opt/jboss/certs/tls.crt
JDBC_PARAMS: sslmode=verify-ca&sslrootcert=/opt/keycloak/db-certs/tls.crt
KC_DB_PASSWORD: t-silent-test-1234/c-green-test-1234/openshift/db-password
type: Opaque

0 comments on commit 26b94a3

Please sign in to comment.