For the complete documentation index, see llms.txt. This page is also available as Markdown.

Installation and deployment of the service

1. Installation and deployment

The service is containerized, and there is a Docker image in a Facephi repository.

docker login facephicorp.jfrog.io  
user: username
pass: token
docker pull facephicorp.jfrog.io/docker-core-pro-fphi/facephi-ine-service:#VERSION#

Where #VERSION# is the specific version number that you want to download (for example, 1.6.0).

2. docker-compose

One way to deploy the service is to create a file docker-compose.yml with the following content:

version: '3.7'

services:
  ine-service:
    ports:
      - "6982:6982"
    volumes:
      - ./config:/service/config
      - ./logs:/service/logs
    image: facephicorp.jfrog.io/docker-core-pro-fphi/facephi-ine-service:latest
    container_name: facephi-ine-service
    environment:
      # Optional JWT protection
      # - FACEPHI_INE_REST_AUTH_ENABLED=true
      # - FACEPHI_INE_REST_AUTH_JWT_SECRET=shared-secret
      # - FACEPHI_INE_REST_AUTH_ACCEPT_AUTHORIZATION_HEADER=true
      # - FACEPHI_INE_REST_AUTH_ACCEPT_API_KEY_HEADER=true
      # - FACEPHI_INE_REST_AUTH_API_KEY_HEADER_NAME=x-api-key

Observe the volumes that are mounted in the container. These volumes are used to store the service configuration files and write the logger output.

Run the following command, inside the folder where the docker-compose.yml file is located, to deploy the service:

3. Configuration

The configuration file can contain the following information:

The configuration file can be passed as a parameter to the service. By default, the service will look for a file called /service/config/config.json.

The configuration precedence order is:

  1. Environment variables FACEPHI_INE_REST_*

  2. config.json

  3. Default API values set by the service before startup

  4. Internal default values of Rest::Manager

JWT authentication is optional and disabled by default.

  • Public endpoints remain accessible without authentication: GET /api/v1/health and GET /api/v1/version.

  • POST /api/v1/facial/authentication requires a valid JWT when JWT authentication is enabled.

  • The service does not expose endpoints GET/POST /config at runtime, so JWT configuration cannot be viewed or modified through a public configuration API.

Supported JWT environment variables:

  • FACEPHI_INE_REST_AUTH_ENABLED

  • FACEPHI_INE_REST_AUTH_JWT_SECRET

  • FACEPHI_INE_REST_AUTH_ACCEPT_AUTHORIZATION_HEADER

  • FACEPHI_INE_REST_AUTH_ACCEPT_API_KEY_HEADER

  • FACEPHI_INE_REST_AUTH_API_KEY_HEADER_NAME

Last updated