Configuration
1. Configure the Qdrant application
Create a qdrant application in your.upsun/config.yaml:
The example above is using a HIGH_MEMORY container. You can refer to the Container profiles documentation for more information.
Available versions
In order to run Qdrant as a standalone application without building it from source, the configuration relies on the Composable image. Each Nix release (channel) comes with specific package versions. You can check which Qdrant version is available on a specific release on the Nix packages search.This is especially important as Qdrant client librairies must use the same minor version(x.y.*) as the server.2. Add the required Qdrant configuration
Qdrant relies on its ownconfig.yaml configuration file in order to start instead of command-line arguments.
Add a new file named qdrant/config.yaml in your project. Note that the qdrant/ directory matches the root: "qdrant" configuration in your .upsun/config.yaml.
You can find the default configuration adapted for Upsun below:
qdrant/config.yaml
3. Connect from your application
To connect to Qdrant from another application in your project, add a relationship in that application configuration block:.upsun/config.yaml
qdrant as the relationship name, your application will have access to QDRANT environments variables.
4. Use the relationship in your application
Connect to Qdrant using the relationship configuration:- Python
- Node.js
Persistent storage
The configuration includes persistent storage through mounts:storage: Stores the main Qdrant database filessnapshots: Stores Qdrant snapshots
Access Qdrant
Qdrant runs as an internal application without external HTTP access. Other applications in your project connect to it using theqdrant.internal hostname through relationships.
For development and debugging, you can use port forwarding to access your Qdrant instance locally:
Exposing Qdrant on the public internet
If you are willing to make the Qdrant database publicly accessible, add a new route to the application in the.upsun/config.yaml file:
.upsun/config.yaml
Exporting Data
Qdrant stores vector collections on disk inside the service container. The recommended export method is the Qdrant Snapshot API.- Open an SSH tunnel to your Qdrant service:
Terminal
6333.
- Create a snapshot for a specific collection:
Terminal
<COLLECTION_NAME>-<TIMESTAMP>.snapshot).
- Download the snapshot:
Terminal
- To list all collections and snapshot all of them:
Terminal
.snapshot files can be restored into any Qdrant instance using the
snapshot recovery endpoint.