Running utilities from the Utility server Docker container
To run utilities, enter the Utility server Docker container container and use a bash shell.
Before you begin
- If you store configuration and data files in the Utility server Docker container, they will be lost the next time you upgrade or restart the Utility server image. The Utility server Docker container and other containers are also not intended to hold large amounts of data. To avoid this, place any files that could be changed into a separate volume mounted to the container as a writable directory. Ensure that all configuration files and data files are written to this directory. Now, when you upgrade the Utility server Docker image, the files you changed in the Utility server Docker container are not lost. You need only again mount the volume to the new Docker container. The files in the directory are also accessible in the host machine, where editing files may be more convenient.
- If you have customizations that must accessed by utilities in the Utility server Docker container, build a custom Docker image for them and put your changes there. See Building a custom Docker image from a deployable package.
Procedure
-
Run
docker ps
to verify that your containers are running. -
Locate your utility container name in the NAMES column.
For example, myproject_utils_1.
-
Start a bash shell by running the following command with the utility container name
docker exec -it <utility_container_name> bash
-
Go to the bin directory.
cd /opt/WebSphere/CommerceServer90/bin
- Run the utility that you need.