Skip to content

Commit

Permalink
Merge pull request #39 from entando/IT-406_MultiarchWorkflow
Browse files Browse the repository at this point in the history
IT-406 test update Oracle driver version to 23.2.0.0
  • Loading branch information
pietrangelo authored Aug 8, 2023
2 parents f1e785c + f4c3155 commit 4f18ff3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Dockerfile.keycloak
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ COPY --chown=jboss:root cli /opt/jboss/tools/cli/
COPY --chown=jboss:root jboss-tools/standalone-configuration.cli /opt/jboss/tools/cli/standalone-configuration.cli
COPY --chown=jboss:root jboss-tools/standalone-ha-configuration.cli /opt/jboss/tools/cli/standalone-ha-configuration.cli

ARG ORACLE_JDBC_DRIVER_VERSION=21.4.0.0.1
ARG ORACLE_JDBC_DRIVER_VERSION=23.2.0.0
RUN export KEYCLOAK_HTTP_PORT=8080 && \
cd /opt/jboss/keycloak/modules/system/layers/base/com/oracle/jdbc/main/ && \
mkdir driver && \
Expand All @@ -32,7 +32,7 @@ ENV JGROUPS_DISCOVERY_PROTOCOL="dns.DNS_PING" \
USER root
RUN mkdir -p "$HOME"; \
chown jboss:jboss "$HOME"; \
chmod g+rwx "$HOME"
chmod g+rwx "$HOME"
USER jboss

EXPOSE 8080
Expand Down
13 changes: 8 additions & 5 deletions cli/databases/oracle/change-database.cli
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,11 @@
/subsystem=datasources/data-source=KeycloakDS: add(jndi-name=java:jboss/datasources/KeycloakDS,enabled=true,use-java-context=true,use-ccm=true, connection-url=jdbc:oracle:thin:@//${env.DB_ADDR:oracle}:${env.DB_PORT:1521}/${env.DB_DATABASE:XE}${env.JDBC_PARAMS:}, driver-name=oracle)
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=user-name, value=${env.DB_USER:SYSTEM})
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=password, value=${env.DB_PASSWORD:oracle})
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=check-valid-connection-sql, value="SELECT 1 FROM dual")
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=background-validation, value=true)
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=background-validation-millis, value=60000)
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=flush-strategy, value=IdleConnections)
/subsystem=datasources/jdbc-driver=oracle:add(driver-name=oracle, driver-module-name=com.oracle.jdbc, driver-xa-datasource-class-name=oracle.jdbc.xa.client.OracleXADataSource)
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=validate-on-match,value=true)
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=valid-connection-checker-class-name, value=org.jboss.jca.adapters.jdbc.extensions.oracle.OracleValidConnectionChecker)
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=initial-pool-size,value=${env.KC_DB_POOL_INITIAL_SIZE:2})
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=min-pool-size,value=${env.KC_DB_POOL_MIN_SIZE:1})
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=max-pool-size,value=${env.KC_DB_POOL_MAX_SIZE:100})
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=stale-connection-checker-class-name, value=org.jboss.jca.adapters.jdbc.extensions.oracle.OracleStaleConnectionChecker)
/subsystem=datasources/data-source=KeycloakDS: write-attribute(name=exception-sorter-class-name, value=org.jboss.jca.adapters.jdbc.extensions.oracle.OracleExceptionSorter)
/subsystem=datasources/jdbc-driver=oracle: add(driver-name=oracle, driver-module-name=com.oracle.jdbc, driver-xa-datasource-class-name=oracle.jdbc.xa.client.OracleXADataSource)

0 comments on commit 4f18ff3

Please sign in to comment.