Running Tentris Using Docker
Pull the Image from the Docker Registry
docker pull ghcr.io/tentris/tentris:latest # get the latest or a specific tag
To start the container, use the following command.
docker run -it \
-v ./tentris-license.toml:/config/tentris-license.toml:ro \
-v ./data:/data \
-p 9080:9080 \
ghcr.io/tentris/tentris:latest
Note: For docker versions older than
v23
, an absolute path or a volume name for the-v
argument (e.g.-v /home/user/data:/data
or-v data:/data
) needs to be provided.
Note: The
./data
directory must exist and must also be accessible to the container. To load data, the SPARQL Graph Store Protocol, the methods of SPARQL Update, or the upload button that is available on the UI (/ui
) may be used.
⚠️ Warning: if you are using colima on macOS to run docker containers, make sure that
mountType
is set tovirtiofs
andvmType
is set tovz
. This can be changed withcolima start --edit
. In our testing other options prevented docker from mounting the license properly.
Container Image Structure
In general, the precedence of configuration is as follows:
- Environment variables
- Configuration file
/config/tentris-server-config.toml
(if provided) - Default values
Environment Variables
TENTRIS_DEFAULT_GRAPH_MODE
: optional, valid values: standalone or union, sets the mode for the default graph (default is standalone)TENTRIS_USER
: optional, string, username to access the Tentris serverTENTRIS_PASS
: optional, string, password to access the Tentris serverTENTRIS_TLS_KEY
: optional, path (inside the container) to TLS key, enables TLSTENTRIS_TLS_CERT
: optional, path (inside the container) to TLS certificate, enables TLSTENTRIS_RDF_FILE
: optional, path (inside the container) to an RDF file that should be loaded on the first initialization
Volumes
/data
(optional): This is where Tentris will store its database, if left out all database state will be lost on container shutdown./config/tentris-license.toml
(required): This is where the Tentris license must be placed./config/tentris-server-config.toml
(optional): Injects a config file. Options passed via environment variables take precedence anddatastore-path
will be overwritten to/data
.
Ports
9080
: TCP port the tentris instance will be running on