How to use env variables for datasource properties in JBOSS EAP 7.3? It does not work on my local machine and in docker also.
Here is datasource part of my standalone-full.xml file
<datasource jta="true" jndi-name="java:/jdbc/powds" pool-name="powpu" enabled="true" use-java-context="true" use-ccm="true">
<connection-url>jdbc:oracle:thin:@${env.CONNECTION_URL}:ddjboss</connection-url>
<driver>oracle</driver>
<pool>
<min-pool-size>1</min-pool-size>
<max-pool-size>15</max-pool-size>
<prefill>true</prefill>
<use-strict-min>false</use-strict-min>
<flush-strategy>FailingConnectionOnly</flush-strategy>
<allow-multiple-users>false</allow-multiple-users>
</pool>
<security>
<user-name>${env.ORACLE_USERNAME}</user-name>
<password>${env.ORACLE_PASSWORD}</password>
</security>
</datasource>
For example I try to start container like here and env values not replacing. docker run -it -p 8080:8080 -p 9990:9990 -p 7001:7001 patient/patient:2.0 -e ORACLE_PASSWORD="cl_cn_local_upd" -e ORACLE_USERNAME="user"
How I set env variable in docker:
ENV CONNECTION_URL=lovalhost:9909