Apama 10.3 | Apama Documentation | Deploying and Managing Apama Applications | Deploying Apama Applications with Docker | Quick start to using an Apama image
Quick start to using an Apama image
The Apama image that we are using here is available on the Docker Store (https://store.docker.com/images/apama-correlator). You must purchase it (free of charge) so that you can use it. After you have done this, proceed as described below.
1. Log in to the Docker Store using your credentials:
docker login
2. Obtain the image from the repository so that it will be available to use:
docker pull store/softwareag/apama-correlator:version
where version is the current Apama version number (a two-digit number such as 10.2).
Note: If you logged in successfully but get an error during the docker pull command, it is likely that there is a spelling mistake or that the image you specified is missing.
3. List the images available to you:
docker images
You should see the image that you pulled in the output of the above command (keep in mind there may be many images if you are using a shared machine).
4. Create a container using the image and run it in Docker:
docker run -d --name container --rm store/softwareag/apama-correlator:version
The above command will "detach" after running the container. You can see it running using the following command:
docker ps
You can interact with the running image in many ways (see the Docker documentation for the appropriate commands), but we will now retrieve the logs from the running container and then stop the container.
5. To examine the log of the running container, enter the following command using the name that was set with the --name container argument of the docker run command.
docker logs container
When the above command is executed, the container identifier or the name which you can find in the output of the docker ps command is taken as a parameter.
6. You can now stop the container:
docker stop container
This also removes the container since it was started with the --rm option.
Running as the sagadmin user within a container
Software AG images are configured not to run processes as root by default within containers. This is standard container practice. All images create a user sagadmin with the user identifier and group identifier of 1724. By default, all processes run in the container, and all RUN commands in Dockerfiles using these images as a base run with that user identifier.
COPY commands may need to specify writing as the sagadmin user via the --chown argument. It is recommended to continue using this user for all of your commands within Docker.
If you need to run as another user, you need to add USER statements to your Dockerfile or the appropriate options to your docker run command.

Copyright © 2013-2018 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.