Deploy with Docker¶
Docker Compose is the recommended option for single-host deployments, local setups, and
smaller-scale environments. Docker is the only thing you install yourself, MATVIS provides the
docker-compose.yml and an example .env, and the compose file pulls every other service
(see What gets deployed) for you.
Prerequisites¶
- Docker: install Docker Engine (Linux) or Docker Desktop (Windows/macOS). This is the only prerequisite you set up yourself. See the Docker install guide.
- MATVIS delivery package: MATVIS provides you with a registry service-account key
(
matvis-registry.key) with the registry path it opens, thedocker-compose.yml, and an example.envfile. - NVIDIA Container Toolkit: the provided
docker-compose.ymlruns the inference services with the NVIDIA runtime, so they need the toolkit to start. Install guide.
1. Authenticate with the registry¶
Use the service-account key MATVIS provided to log in to the container registry:
cat matvis-registry.key | docker login -u _json_key --password-stdin \
https://europe-west3-docker.pkg.dev
You should see a success message after login.
2. Fill in the .env file¶
MATVIS provides the .env file alongside the docker-compose.yml, with working defaults. Open it
and fill in every <PLACEHOLDER>:
- the license (
KEYGEN_ACCOUNT_ID,KEYGEN_ACTIVATION_TOKEN,LICENSE_KEY), or for air-gappedAIR_GAPPED=trueandLICENSE_FILE, and uncomment the license volume indocker-compose.yml; - the secrets;
- the admin dashboard user.
Adjust ports, performance, logging or ICAP as needed. Every variable you can set is in the Configuration reference. The bundled PostgreSQL is used unless you point MATVIS at a database of your own, see Managed PostgreSQL.
Generate each secret with openssl rand -base64 24, and PSEUDONYM_SECRET with
openssl rand -base64 32: it needs at least 32 bytes. For ICAP, see ICAP proxy integration.
Use a secrets manager in production
Keep .env out of version control and off shared disks. In production, hold the secrets in a
secrets manager (for example HashiCorp Vault or your cloud provider's) and write .env from it
when you deploy.
The provided docker-compose.yml does not terminate TLS: the services speak plain HTTP. Put a
TLS-terminating reverse proxy or load balancer in front, and set HTTPS_ENABLED=true as described
in the Configuration reference.
The provided docker-compose.yml runs the filter services with the NVIDIA runtime, so the NVIDIA
Container Toolkit must be installed for them to start. Set GPU_ACCELERATION=True in .env to run
inference on the GPU. The language filter runs on CPU only.
3. Start MATVIS¶
From the directory containing the provided docker-compose.yml and your .env:
After starting, it can take up to 5 minutes until all services are available.
With default ports you will find:
- the dashboard at http://localhost:3000
- the API at http://localhost:8000
- the ICAP server on port
1344, whenICAP_ENABLED=true
localhost only works when you access the services from the host itself. Otherwise use the
host's IP address, and make sure the ports in .env are open for inbound traffic.
Next steps¶
- Follow the Quick start: one configuration for all four enforcement points, an API key, your first screened requests.
- Put MATVIS in front of your agents: Integrations.