4 Replies Latest reply on Feb 1, 2018 12:57 AM by Isa B

    Docker variables in JBoss

    Isa B Newbie

      Hi All

       

      I am currently working on containerising our JBoss application. I have managed to successfully create a working JBoss Application container,however I have hard coded many of configs like Datasource ip/user/password as well as system properties.

       

      My Dockerfile has basically the following steps:

      1. From Centos
      2. Download and extract EAP and JAVA
      3. Copy a configuration.sh script and execute it
        1. This script starts jboss, runs a few cli to configure Datasources etc and stops JBoss
      4. Lastly Start JBoss

       

      If I want to move my code to another environment DEV -> UAT as an example. I would need to change or create a new configuration script that has the new Datasource URL/User/Password etc. This would mean I would have a different container for each environment.

       

      My question is:

       

      Is it possible to use some sort of variable for config within standalone.xml