Before you start
- A Linux host with systemd and Docker 20.10 or later, or Podman 4 or later. The image is published for amd64 and arm64. Start with about 4 vCPU and 8 GiB of memory, plus disk for the state directory (roughly 200 bytes per scanned object or table) and spill space for large listings.
- Outbound HTTPS (443) to the TigerGate API host of your region, directly or through
https_proxy, and to the image registry (Docker Hub or your mirror). Nothing connects in. - Network reach to the targets from the host: each database port (for example 5432, 3306, 1433, 1521, 27017) and each file share (SMB 445, NFS 2049).
- Read-only credentials for each target: database users with
SELECTon the schemas to classify, and share accounts. - A synchronized clock (NTP). TLS and token checks fail on a skewed clock.
- An organization API key (
tg_). See Before you deploy.
Deploy
Create the deployment
In TigerGate, go to DSPM → Deployments → Add deployment and choose On-prem. Enter a Site name (1 to 63
letters, digits, dots, underscores or hyphens, for example
dc-frankfurt-1), the TigerGate region and the scan
settings, then select Create deployment and enrollment token. Copy the token: it is shown once.Render the files
The wizard’s Terraform step shows the module block. Tick both options that keep the key and the token out of
Terraform state to get the form below, then apply it on the scanner host, as root or with sudo:
Install
Export the API key and the token, then run the install commands:The install commands copy the files to
/etc/tigergate-dspm, write api-key.env and enrollment.env (mode
0600, without putting either value on the command line), create the state directory owned by uid 65532, pull the
image, enable the timer and run the first tick. That tick registers the site and posts its preflight checks.output_dir, copy the directory to the host, and
run the install commands there. If TIGERGATE_DSPM_API_KEY is empty, the install commands say so and write no key
file, and the unit fails until you write it.
Targets
Targets are managed per deployment on the Configuration tab, up to 150 per deployment.| Kind | Default port | Notes |
|---|---|---|
| PostgreSQL, MySQL, MariaDB, SQL Server, Oracle | 5432, 3306, 3306, 1433, 1521 | TLS is required by default. |
| SAP HANA, Trino, Presto, Hive | 30015, 8080, 8080, 10000 | |
| MongoDB | 27017 | The credential file may give a uri. |
| Kafka | 9092 | The host is a broker list. TLS is off by default. |
| SMB share, CIFS share | 445 | A share, an optional folder and an optional domain. |
| NFS export | 2049 | The share is the export path. |
credentials_dir, which is
mounted read-only into the container. It holds JSON or the password alone:
password, secret, token, key, uri or private_key field.
What the module renders
| File | Content |
|---|---|
scanner.env | Non-secret settings: the API URL, the site name, the state directory, concurrency, log level and proxy. |
enrollment.env | DSPM_ENROLLMENT_TOKEN=..., mode 0600. Only the first tick needs it; the scanner then keeps its own credential in the state directory. The file must stay, because the unit reads it, but you can empty it. |
api-key.env | DSPM_API_KEY=..., mode 0600. Every call needs it. |
<name>.service | A oneshot unit that runs one tick with a read-only root filesystem, every capability dropped, no-new-privileges, uid 65532, CPU and memory limits, and the state directory as the only writable mount. |
<name>.timer | Starts the unit every 15 minutes (schedule). systemd never starts a second copy while one runs. |
docker-compose.yml | The same container for hosts managed with Compose: docker compose run --rm scanner. |
docker/ submodule (see the module’s
examples/docker-host). That container does not read the env files, so give the API key as api_key_file (a host file
mounted read-only, which keeps the key out of Terraform state) or as tigergate_api_key.
If you pass
enrollment_token or tigergate_api_key to the module, the value is also kept in Terraform state,
because a local file has no write-only form. The install-commands path keeps both out of state.Edge cases
- Proxies:
https_proxyapplies to the TigerGate API. Keep your databases and file servers inno_proxy. - TLS interception: a proxy that re-signs TLS needs its CA trusted. Put a CA bundle in
credentials_dirand setSSL_CERT_FILEinextra_env. - Podman: set
container_cli = "/usr/bin/podman". Rootless Podman needs the state directory owned by the mapped uid. - SELinux: label the state and credentials directories for containers, for example
chcon -Rt container_file_t /var/lib/tigergate-dspm. - Targets only reachable through the host’s routes or DNS: set
network_mode = "host". - Several sites on one host: use a different
name_prefix,site_nameandstate_dirfor each. - Backups: the state directory holds the scanner credential and the incremental state (object keys, sizes, hashes and classes found, never contents). Keep it at mode 0700. Back it up to avoid a full rescan after a host rebuild.
Operate the deployment
- Check a target or the connection: run the command that
terraform output -raw preflight_commandprints. It checks TigerGate and every target, prints the results and posts them to the console. - Logs:
journalctl -u tigergate-dspm.service -n 100 --no-pager(the unit is named aftername_prefix). - Rotate the API key: rewrite
api-key.env. The next tick reads it. - Remove: select Revoke on the deployment, then disable the timer and delete the files.