Hi,

   In Openshift2, you could reference a MySQL DB from a Tomcat
   cartridge just defining some environment variables, that were
   replaced automatically in the JNDI definition at the context.xml.

       <Resource name="jdbc/piadmin"
       
url="jdbc:mysql://*${OPENSHIFT_MYSQL_DB_HOST}*:*${OPENSHIFT_MYSQL_DB_PORT}*/*${OPENSHIFT_APP_NAME}*"
       driverClassName="com.mysql.jdbc.Driver"
       username="*${OPENSHIFT_MYSQL_DB_USERNAME}*"
       password="*${OPENSHIFT_MYSQL_DB_PASSWORD}*"
       auth="Container"
       type="javax.sql.DataSource"
       maxActive="20"
       maxIdle="5"
       maxWait="10000"
       />

   In OpenShift3, this doesnt work. The tokens in context.xml are not
   replaced by their corresponding environment variable values. What is
   then the correct way to connect a JNDI datasource in a Tomcat S2I
   like jboss-webserver30-tomcat7-openshift?

   Thanks,

   Andrés.

_______________________________________________
users mailing list
[email protected]
http://lists.openshift.redhat.com/openshiftmm/listinfo/users

Reply via email to