Connect object storage
Once an S3-compatible object storage backend is ready - whether self-hosted or cloud-based - Relution needs to be configured to use it.
Prerequisites
The following information is needed from the object storage provider:
| Setting | Description |
|---|---|
| Endpoint | The S3 API URL. Optional for AWS S3, where the endpoint is derived from the region. |
| Access Key | Authentication key ID |
| Secret Key | Authentication secret |
| Bucket Name | The storage bucket name. Relution does not create the bucket itself, so it must already exist. It is used only by this Relution instance. |
| Region | Region of the bucket (optional, default eu-west-1). For AWS S3, the actual bucket region, e.g. eu-central-1. |
If the access key and secret key are left empty, Relution authenticates via the instance profile. This is only useful when running on AWS EC2 with an assigned IAM role.
The configuration examples below use example values matching SeaweedFS Setup →. If a different backend or provider is used, adjust them accordingly.
Configuration
Choose one of the two options below. Both achieve the same result.
Option A: Using application.yml
Add the following to the application.yml:
relution:
storage:
resourceStorageType: S3
s3:
customEndpoint: http://seaweedfs:8333
accessKey: %YOUR-ACCESS-KEY%
secretKey: %YOUR-SECRET-KEY%
bucketName: relution
region: eu-west-1 # optional, default: eu-west-1
Option B: Using Environment Variables
Add these environment variables to the relution service in the compose.yaml:
services:
relution:
environment:
- RELUTION_STORAGE_RESOURCESTORAGETYPE=S3
- RELUTION_STORAGE_S3_CUSTOMENDPOINT=http://seaweedfs:8333
- RELUTION_STORAGE_S3_ACCESSKEY=%YOUR-ACCESS-KEY%
- RELUTION_STORAGE_S3_SECRETKEY=%YOUR-SECRET-KEY%
- RELUTION_STORAGE_S3_BUCKETNAME=relution
- RELUTION_STORAGE_S3_REGION=eu-west-1 # optional, default: eu-west-1
The values are written without quotation marks, because Docker Compose keeps quotation marks as part of the value in this list form. Existing entries under environment: (e.g. TZ) remain in place.
If the object storage is to be encrypted with a customer-provided key, this must be done before the first start: Server-Side Encryption (SSE-C) →
Starting the Services
Pull the latest images:
docker compose pullStart or restart the containers:
docker compose up -dRelution will automatically begin migrating content from the
resourcedatabase table to the object storage bucket.
Not all content moves to the bucket:
- Files up to 512 KB remain in the database (
relution.storage.s3.smallFileThreshold; the value0disables this rule). - Certificates and private keys always remain encrypted in the database.
The first migration runs on the first start with object storage. Resources still in the database afterwards are processed daily at 3:00 a.m. (relution.storage.s3.resourceMigrationSchedule). Failed transfers are retried after 5 minutes.
Monitoring Progress
Watch the migration progress in the logs:
docker logs -f relution
Each file transferred to object storage appears as Saving file <UUID> in S3 at key <Key>, large files as Saving large file <UUID> in S3 via multipart upload. With the default log level, Relution does not output a total count or percentage. Failed transfers appear as Scheduling retry attempt for resource migration of <UUID> and are retried later. Resources that cannot be migrated appear as Won't migrate resource <UUID>.
Files being created can also be verified by checking the object storage backend (e.g., via the SeaweedFS web UI or the cloud provider’s console).