Docker Compose Setup
Learn how to self-host Trieve with Docker Compose
Docker Compose
The Docker Compose self hosted option is the easiest way to get started self hosting Trieve.
Things you need
- Domain name
- System with at least 4 CPU cores and 8GB of RAM (excluding the cpu embedding servers)
- System with at least 4 CPU cores and >25GB of RAM (including the cpu embedding servers)
Install Docker
Clone Trieve repository
Create .env
file
Start Trieve Services
Start Embedding servers
We offer 2 docker-compose files for embedding servers. One for GPU and one for CPU.
or
* Note on embedding servers. If you want to use a separate GPU enabled device for embedding servers you will need to update the following parameters
Setup Caddy reverse proxy
Install Caddy
Edit the Caddyfile
Add the following configuration
Start Caddy, you may also need to reload the service
Set the following A records for your domain to point to the server IP address.
Edit .env
Most values can be left as default, the ones you do need to edit are
Authorize keycloak redirect URLs
Go to auth.yourdomain.com and login with the default credentials (user: admin password: aintsecure)
- Change the Realm from master to trieve
- Go to Clients -> vault -> Settings
- Add the following to the Valid Redirect URIs and Valid Post Logout Redirect URIs
Testing
The fastest way to test is using the Trieve CLI
And there you have it. Your very own Trieve stack. Happy hacking 🚀