Applies to: QLM Enterprise
If you run your application within a docker container, QLM can bind the license to the hostname of the docker container.
There are two ways you can configure QLM to bind the license to a Docker Container:
- By setting the ELicenseBinding to QlmUniqueSystemIdentifier2
- By setting the ELicenseBinding to DockerContainer
To detect that your application is running in a Docker Container, QLM relies on the following environment variable: QLM_RUNNING_IN_DOCKER_CONTAINER
Therefore, when you create your Docker container image, you must set the QLM_RUNNING_IN_DOCKER_CONTAINER environment variable to True.
Example of a Dockerfile used to create an image:
COPY ./publish .
The following API is also available to detect if your application is running in a Docker Container (requires that your image sets the QLM_RUNNING_IN_DOCKER_CONTAINER environment variable): QlmHardware.RunningInDockerContainer()
QlmHardware hw = new QlmHardware();
bool isRunningInDockerContainer = hw.RunningInDockerContainer ();