Creating Docker containers

On a Docker engine, you must create a separate container for each IBM® Storage Protect server that you want to connect to Data Management Service.

Before you begin

For each container, you need to provide a directory on the local system to store configuration data and logs. Consider the following parameters and requirements while running the Docker commands:
  • --mount type=bind: To specify where a container should store its files, use the --mount type=bind parameter with the docker create command used to create a container.
  • By default, files stored in the specified directory are owned by a user with UID=1001, GID=1001. Therefore, you need to make sure that the directory's permissions give this user read/write access. If you want the container to use a different user and group ID, then you can override the UID and GID by specifying the -e UID=uid and -e GID=gid parameters on the docker create command.
    Restriction: The user and group IDs that are specified by -e UID= and -e GID= parameters cannot be zero.
  • If the container will be running on a system that does not have direct access to the internet, you will need to configure the container to use an HTTP proxy. To configure, specify the -e HTTP_PROXY=<https://address:port> parameter on the docker create command.
Note: Docker commands must be executed by the root user or a user who is a member of the Docker group. If an user is not a member of the Docker group, you must prefix all the Docker commands with sudo.

Procedure

Repeat the following steps for each IBM Storage Protect server to which you want to connect.

  1. Create an empty directory in which to store connection agent logs and state data. Set the directory's permissions and/or ownership to allow the container to write into the directory.
  2. Create a container in which to run the Connection Agent using docker create:
    docker create --name <sp-server-name> --mount type=bind,src=<path_to_empty_directory>,dst=/opt/ibm/defender/persist -e UID=<uid> -e GID=<gid>
    eagle-agent:latest
  3. Start the container using docker start:
    docker start <sp-server-name>
  4. Use docker exec to connect to the container and configure using dcli command.
    docker exec -i <sp-server-name> bash
    dcli server register ...
    dcli claim register ...
    ^D
    Or, you can issue the following commands:
    docker exec <sp-server-name> dcli server register ... -y
    docker exec <sp-server-name> dcli claim register ...