Basic Installation: Docker
The basic installation does not include the Liveness and Identification features. To use these functionalities, see to the Advanced Installation guide.
Distribution Channels
We distribute our container images via the following container registries:
Images are Red Hat Certified and fully identical. The face-api
image is based on the official ubi9-minimal
image, maintained by Red Hat. The image is configured to be run as an arbitrarily assigned UID (OpenShift-ready).
Supported Version Tags
- nightly-cpu/nightly-gpu — nightly build for development purposes, it should never be used in production
- A.B.C.D-develop-cpu/A.B.C.D-develop-gpu — release candidate build
- A.B.C.D-cpu/A.B.C.D-gpu — stable release build
To obtain the latest SDK / document database / service wrapper version, pull the container image with the newest tag version according to the description above.
For more information about versioning of the Face SDK, see Getting Started.
Installation
1. Install Docker Desktop for your OS following the link:
2. Start the Docker Desktop application.
3. Pull the Face SDK image to the local machine from one of the available distribution channels:
docker pull regulaforensics/face-api:latest
docker pull regulaforensics/face-api:latest
docker pull regulaforensics/face-api:latest
4. Run the container image by passing the license to it. You may either use the license file or the Base64 string.
Put the license file to your OS home directory:
C:\%HOMEPATH%\Desktop\regula.license
/home/<username>/regula.license
/Users/<username>/regula.license
Open the command line or Terminal and run the following command.
- For CPU:
docker run -d -p 41101:41101 -v C:\%HOMEPATH%\Desktop\regula.license:/app/extBin/unix/regula.license regulaforensics/face-api:latest
docker run -p 41101:41101 -v ~/regula.license:/app/extBin/unix/regula.license regulaforensics/face-api:latest
docker run -p 41101:41101 -v ~/regula.license:/app/extBin/unix/regula.license regulaforensics/face-api:latest
- For GPU:
docker run -d -p 41101:41101 --gpus all -v C:\%HOMEPATH%\Desktop\regula.license:/app/extBin/unix/regula.license regulaforensics/face-api:latest-gpu
docker run -p 41101:41101 --gpus all -v ~/regula.license:/app/extBin/unix/regula.license regulaforensics/face-api:latest-gpu
docker run -p 41101:41101 --gpus all -v ~/regula.license:/app/extBin/unix/gpu/regula.license regulaforensics/face-api:latest-gpu
The face-api version in the code above can be passed in the following formats:
face-api:latest
face-api:latest-gpu
face-api:6-gpu
face-api:6.1-gpu
face-api:6.1.2.3-cpu
The table below shows what you'll get depending on the version format you use:
Version tag | Major update | Minor update | Patch update |
---|---|---|---|
latest |
|||
latest-gpu |
|||
6-gpu |
|||
6.1-gpu |
|||
6.1.2.3-cpu |
For production environments, the best practice is to use the full version format, such as 6.1.2.3-cpu
. This practice helps mitigate version/configuration drift, ensuring consistency. However, in development and test environments, versions 6-gpu
or 6.1-gpu
may be utilized.
We strongly advise against using the latest
and latest-gpu
tag in production environments, as it may lead to unpredictable changes in infrastructure. Opting for explicit version tags provides better control and stability in production.
Warning
To run the Face SDK Web API GPU version, your Docker environment must be configured to work with NVIDIA GPUs. GPU version installation requires a video card on the base machine. Make sure you have installed the NVIDIA driver (version = 520). For more information, visit the official docker documentation and NVIDIA documentation.
Alternatively, you can pass the license as Base64 string via the environment variable REGULA_LICENSE, rather than using the path to the license file:
docker run -d -p 41101:41101 -e REGULA_LICENSE="<BASE64_STRING>" regulaforensics/face-api:latest
docker run -d -p 41101:41101 -e REGULA_LICENSE="<BASE64_STRING>" regulaforensics/face-api:latest
docker run -d -p 41101:41101 -e REGULA_LICENSE="<BASE64_STRING>" regulaforensics/face-api:latest
where <BASE64_STRING>
is your license in the Base64 format.
5. To make sure that the service is up and running, check the http://localhost:41101/ address in a web browser.
FAQ
Does Docker Desktop support Windows Server?
Docker Desktop doesn't support the Windows Server version installation. See the corresponding reference in the Docker documentation.
How to convert the license file to base64 format?
Have a look at the Regula's Help Center article How to convert a license file to Base64 .
How to open command line or Terminal?
Press the WIN key, type cmd
, and press Enter.
Press the Ctrl + Alt + T key combination.
Have a look at the Apple's Terminal User Guide.