Creating a container for Domino
After you have set up a new Domino server using a temporary container, create the container to run the Domino server.
About this task
- Before you complete this procedure, decide what execution mode you want to use to run the container, interactive or detached. Interactive mode allows yout to interact with the Domino server directly through the Docker terminal window. You should always run a container in the specified mode. For more information, see Docker run command arguments.
- If your Domino server ID is password-protected and you plan to run your
container in detached mode (-d), before you complete this procedure, create
a secrets file to store the password. The file must be accessible by your
Docker container. Use the docker cp command to copy the
file to the Docker container. The Domino server reads the password from the
secrets file. The file can be created manually or through orchestration
software such as Docker Swarm or Kubernetes. For more information, see their
documentation:
- Docker: Manage sensitive data with Docker secrets
- Kubernetes: Secrets
- If you use podman, replace docker with
podman in the commands in this procedure. For
example:
podman run -it --name <container name> -v <docker volume name>:<data directory> --hostname <hostname> --cap-add=SYS_PTRACE -p <HostPort:ContainerPort> <image>
Procedure
To create and automatically start the container, issue the run command that
applies to your situation:
To use interactive
mode:
docker run -it --name <container name> -v <docker volume name>:<data directory>
--hostname <hostname> --cap-add=SYS_PTRACE -p <HostPort:ContainerPort> <image>
Tip: -it can be omitted. A container runs in
interactive mode by default.
For example:
docker run -it --name domino1101 -v notesdata:/local/notesdata --hostname docker.renovations.com
--cap-add=SYS_PTRACE -p 8585:8585 -p 1352:1352 -p 443:443 domino-docker:V1101
To
use detached mode with a secrets file that contains a password for the
server ID
file:docker run -d --name <container name> -v <docker volume name>:/local/notesdata
--hostname <hostname> --cap-add=SYS_PTRACE --env secretpwfile=<path to secrets file>
<-p HostPort:ContainerPort> <image>
For
example:
docker run -d --name domino1101 -v notesdata:/local/notesdata --hostname docker.renovations.com
--cap-add=SYS_PTRACE --env secretpwfile=/local/notesdata/secret/mysecret.sth -p 8585:8585 -p 1352:1352
-p 443:443 domino-docker:V1101
To
use detached mode without a secrets file:
docker run -d --name <container name> -v <docker volume name>:/local/notesdata
--hostname <hostname> --cap-add=SYS_PTRACE <-p HostPort:ContainerPort> <image>
For
example:
docker run -d --name domino1101 -v notesdata:/local/notesdata --hostname docker.renovations.com
--cap-add=SYS_PTRACE -p 8585:8585 -p 1352:1352 -p 443:443 domino-docker:V1101
Results
The Domino server container is created and the Domino server starts.