Update Configuration File Options
@@ -1 +1,214 @@
|
||||
Detailed explanation of `config.json`
|
||||
# Configuration File Options
|
||||
|
||||
This document describes configuration settings for **Repertory** across all provider types — S3, Sia, and Remote — with ✅ meaning settings update live and ❌ meaning they require a restart.
|
||||
|
||||
## 🛠 Common Settings (S3, Sia, Remote)
|
||||
|
||||
| Setting | Description | Live Update |
|
||||
|---------|-------------|-------------|
|
||||
| ApiUser | API username for authentication | ❌ |
|
||||
| ApiPassword | API password for authentication | ❌ |
|
||||
| ApiPort | API listening port | ❌ |
|
||||
| DatabaseType | Storage backend type (e.g., rocksdb) | ❌ |
|
||||
| DownloadTimeoutSeconds | Max time in seconds before a download is aborted | ✅ |
|
||||
| EnableDownloadTimeout | Whether download timeout is enforced | ✅ |
|
||||
| EnableDriveEvents | Enable event tracking for drive operations | ✅ |
|
||||
| EventLevel | Logging verbosity (info, debug, etc.) | ✅ |
|
||||
| EvictionDelayMinutes | Delay before cached files are evicted | ✅ |
|
||||
| EvictionUseAccessedTime | Use last access time for eviction logic | ✅ |
|
||||
| HighFreqIntervalSeconds | Interval for high-frequency tasks | ❌ |
|
||||
| LowFreqIntervalSeconds | Interval for low-frequency tasks | ❌ |
|
||||
| MedFreqIntervalSeconds | Interval for medium-frequency tasks | ❌ |
|
||||
| MaxCacheSizeBytes | Maximum cache size in bytes | ✅ |
|
||||
| MaxUploadCount | Max simultaneous uploads | ✅ |
|
||||
| OnlineCheckRetrySeconds | Seconds between online check retries | ✅ |
|
||||
| PreferredDownloadType | Download strategy (default, streaming, etc.) | ✅ |
|
||||
| RetryReadCount | Number of read retries before failing | ✅ |
|
||||
| RingBufferFileSize | Size of the ring buffer file in MB | ✅ |
|
||||
| TaskWaitMs | Delay between queued tasks in ms | ✅ |
|
||||
| Version | Config schema version | ✅ |
|
||||
|
||||
---
|
||||
|
||||
## ☁ S3 Provider
|
||||
|
||||
### Description
|
||||
Provides cloud storage access using S3-compatible APIs, with optional transparent encryption passthrough.
|
||||
|
||||
### Example `config.json`
|
||||
```json
|
||||
{
|
||||
"ApiPassword": "<random generated rpc password>",
|
||||
"ApiPort": 10100,
|
||||
"ApiUser": "repertory",
|
||||
"DatabaseType": "rocksdb",
|
||||
"DownloadTimeoutSeconds": 30,
|
||||
"EnableDownloadTimeout": true,
|
||||
"EnableDriveEvents": false,
|
||||
"EventLevel": "info",
|
||||
"EvictionDelayMinutes": 1,
|
||||
"EvictionUseAccessedTime": false,
|
||||
"HighFreqIntervalSeconds": 30,
|
||||
"LowFreqIntervalSeconds": 3600,
|
||||
"MaxCacheSizeBytes": 21474836480,
|
||||
"MaxUploadCount": 5,
|
||||
"MedFreqIntervalSeconds": 120,
|
||||
"OnlineCheckRetrySeconds": 60,
|
||||
"PreferredDownloadType": "default",
|
||||
"RemoteMount": {
|
||||
"ApiPort": 20100,
|
||||
"ClientPoolSize": 20,
|
||||
"Enable": false,
|
||||
"EncryptionToken": ""
|
||||
},
|
||||
"RetryReadCount": 6,
|
||||
"RingBufferFileSize": 512,
|
||||
"S3Config": {
|
||||
"AccessKey": "<my access key>",
|
||||
"Bucket": "<my bucket name>",
|
||||
"EncryptionToken": "",
|
||||
"Region": "any",
|
||||
"SecretKey": "<my secret key>",
|
||||
"TimeoutMs": 60000,
|
||||
"URL": "http://localhost:9000",
|
||||
"UsePathStyle": true,
|
||||
"UseRegionInURL": false
|
||||
},
|
||||
"TaskWaitMs": 100,
|
||||
"Version": 1
|
||||
}
|
||||
```
|
||||
|
||||
### S3-specific Settings
|
||||
|
||||
| Setting | Description | Live Update |
|
||||
|---------|-------------|-------------|
|
||||
| S3Config.AccessKey | AWS/S3 access key | ❌ |
|
||||
| S3Config.Bucket | Bucket name | ❌ |
|
||||
| S3Config.EncryptionToken | Encryption key/token for encrypted buckets | ❌ |
|
||||
| S3Config.Region | S3 region | ❌ |
|
||||
| S3Config.SecretKey | AWS/S3 secret key | ❌ |
|
||||
| S3Config.TimeoutMs | Timeout for S3 API calls in ms | ✅ |
|
||||
| S3Config.URL | Endpoint URL | ❌ |
|
||||
| S3Config.UsePathStyle | Use path-style addressing | ✅ |
|
||||
| S3Config.UseRegionInURL | Include region in endpoint URL | ✅ |
|
||||
|
||||
---
|
||||
|
||||
## 💠 Sia Provider
|
||||
|
||||
### Description
|
||||
Integrates with the Sia renterd backend for decentralized cloud storage.
|
||||
|
||||
### Example `config.json`
|
||||
```json
|
||||
{
|
||||
"ApiPassword": "<random generated rpc password>",
|
||||
"ApiPort": 10000,
|
||||
"ApiUser": "repertory",
|
||||
"DatabaseType": "rocksdb",
|
||||
"DownloadTimeoutSeconds": 30,
|
||||
"EnableDownloadTimeout": true,
|
||||
"EnableDriveEvents": false,
|
||||
"EventLevel": "info",
|
||||
"EvictionDelayMinutes": 1,
|
||||
"EvictionUseAccessedTime": false,
|
||||
"HighFreqIntervalSeconds": 30,
|
||||
"HostConfig": {
|
||||
"AgentString": "Sia-Agent",
|
||||
"ApiPassword": "<renterd api password>",
|
||||
"ApiPort": 9980,
|
||||
"ApiUser": "",
|
||||
"HostNameOrIp": "localhost",
|
||||
"Path": "",
|
||||
"Protocol": "http",
|
||||
"TimeoutMs": 60000
|
||||
},
|
||||
"LowFreqIntervalSeconds": 3600,
|
||||
"MaxCacheSizeBytes": 21474836480,
|
||||
"MaxUploadCount": 5,
|
||||
"MedFreqIntervalSeconds": 120,
|
||||
"OnlineCheckRetrySeconds": 60,
|
||||
"PreferredDownloadType": "default",
|
||||
"RemoteMount": {
|
||||
"ApiPort": 20000,
|
||||
"ClientPoolSize": 20,
|
||||
"Enable": false,
|
||||
"EncryptionToken": ""
|
||||
},
|
||||
"RetryReadCount": 6,
|
||||
"RingBufferFileSize": 512,
|
||||
"SiaConfig": {
|
||||
"Bucket": "my_bucket"
|
||||
},
|
||||
"TaskWaitMs": 100,
|
||||
"Version": 1
|
||||
}
|
||||
```
|
||||
|
||||
### Sia-specific Settings
|
||||
|
||||
| Setting | Description | Live Update |
|
||||
|---------|-------------|-------------|
|
||||
| HostConfig.AgentString | User-agent string for API requests | ✅ |
|
||||
| HostConfig.ApiPassword | renterd API password | ❌ |
|
||||
| HostConfig.ApiPort | renterd API port | ❌ |
|
||||
| HostConfig.ApiUser | renterd API user | ❌ |
|
||||
| HostConfig.HostNameOrIp | renterd host address | ❌ |
|
||||
| HostConfig.Path | API path | ❌ |
|
||||
| HostConfig.Protocol | http or https | ✅ |
|
||||
| HostConfig.TimeoutMs | API timeout in ms | ✅ |
|
||||
| SiaConfig.Bucket | Target Sia bucket | ❌ |
|
||||
|
||||
---
|
||||
|
||||
## 🔗 Remote Provider
|
||||
|
||||
### Description
|
||||
Connects to another Repertory instance over the network.
|
||||
|
||||
### Example `config.json`
|
||||
```json
|
||||
{
|
||||
"ApiPassword": "<random generated rpc password>",
|
||||
"ApiPort": 10010,
|
||||
"ApiUser": "repertory",
|
||||
"EnableDriveEvents": false,
|
||||
"EventLevel": "info",
|
||||
"RemoteConfig": {
|
||||
"ApiPort": 20000,
|
||||
"EncryptionToken": "<my secure password>",
|
||||
"HostNameOrIp": "192.168.1.10",
|
||||
"MaxConnections": 20,
|
||||
"ReceiveTimeoutMs": 120000,
|
||||
"SendTimeoutMs": 30000
|
||||
},
|
||||
"TaskWaitMs": 100,
|
||||
"Version": 1
|
||||
}
|
||||
```
|
||||
|
||||
### Remote-specific Settings
|
||||
|
||||
| Setting | Description | Live Update |
|
||||
|---------|-------------|-------------|
|
||||
| RemoteConfig.ApiPort | Remote instance API port | ❌ |
|
||||
| RemoteConfig.EncryptionToken | Token used for secure communication | ❌ |
|
||||
| RemoteConfig.HostNameOrIp | Remote instance hostname/IP | ❌ |
|
||||
| RemoteConfig.MaxConnections | Max simultaneous connections | ✅ |
|
||||
| RemoteConfig.ReceiveTimeoutMs | Receive timeout in ms | ✅ |
|
||||
| RemoteConfig.SendTimeoutMs | Send timeout in ms | ✅ |
|
||||
|
||||
---
|
||||
|
||||
## 🔄 Updating Settings via CLI
|
||||
|
||||
You can update most settings directly from the CLI using dotted notation for nested values.
|
||||
|
||||
```bash
|
||||
repertory -set S3Config.Bucket my_bucket_name
|
||||
```
|
||||
|
||||
**Rules:**
|
||||
- Nested values (with a dot `.` in the name) **❌ do not update live** — restart is required.
|
||||
- All others **✅ can be updated live**.
|
||||
|
Reference in New Issue
Block a user