-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathexample-config.yaml
More file actions
203 lines (184 loc) · 8.2 KB
/
Copy pathexample-config.yaml
File metadata and controls
203 lines (184 loc) · 8.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
server:
address: "0.0.0.0:9000" # S3-compatible API endpoint
management_address: "0.0.0.0:9001" # Web dashboard + REST API (remove to disable)
access_key: "your-gateway-key" # Your apps authenticate with this
secret_key: "your-gateway-secret" # Your apps authenticate with this
region: "us-east-1" # Reported region; any value works for most clients
auth_off: false # true = disable auth for trusted internal networks only
data_dir: "/data" # Used by SQLite for the database file and disk cache
# ── Database backend ──────────────────────────────────────────────────────────
#
# Skein defaults to SQLite — zero configuration, works great for one server.
# Switch to PostgreSQL or MySQL when you need:
# - Multiple Skein instances sharing state (horizontal scaling / HA)
# - Querying usage data from Grafana, Metabase, or other BI tools
# - An existing DB server you already manage and back up
#
# SQLite (default — no extra config needed):
database:
driver: "sqlite"
# PostgreSQL example:
# database:
# driver: "postgres"
# dsn: "postgres://skein:yourpassword@localhost:5432/skein?sslmode=disable"
# MySQL / MariaDB example:
# database:
# driver: "mysql"
# dsn: "skein:yourpassword@tcp(localhost:3306)/skein"
# ── Routing strategy ─────────────────────────────────────────────────────────
#
# Controls how Skein selects which provider account receives each upload.
#
# "default" Bucket-level: each bucket is assigned one account at creation.
# Auto-selects the account with the most remaining capacity.
#
# "round-robin" Object-level: distributes objects evenly across all accounts.
#
# "multi-redundancy" Object-level: writes every object to `copies` accounts
# simultaneously. Reads failover automatically.
#
# "object-type" Object-level: routes by Content-Type (e.g. images → fast CDN,
# archives → cheap bulk storage).
#
# "file-size" Object-level: routes by object size (e.g. large files → bulk,
# small files → fast tier).
#
# "space-distribution" Object-level: probabilistic selection weighted by remaining
# capacity. Balances fill levels across providers.
routing:
strategy: "default"
# Uncomment for multi-redundancy:
# strategy: "multi-redundancy"
# redundancy:
# copies: 2
# accounts: [] # empty = all enabled accounts
# Uncomment for object-type routing:
# strategy: "object-type"
# object_type:
# rules:
# - content_type_prefix: "image/"
# accounts: ["fast-provider"]
# - content_type_prefix: "video/"
# accounts: ["bulk-provider"]
# Uncomment for file-size routing:
# strategy: "file-size"
# file_size:
# rules:
# - min_size_mb: 100
# accounts: ["bulk-provider"]
# ── Provider accounts ─────────────────────────────────────────────────────────
#
# Add as many accounts as you need. Skein routes across all enabled accounts
# based on the strategy above.
#
# limits.storage_gb Cap for routing decisions. -1 = unlimited.
# limits.egress_gb_per_month Tracked and displayed; not enforced. -1 = unlimited.
# limits.requests_per_month Tracked and displayed; not enforced. -1 = unlimited.
accounts:
# ── Backblaze B2 ──────────────────────────────────────────────────────────
# Cost-effective bulk storage. No egress fees when served via Cloudflare CDN.
- id: "b2-primary"
name: "Backblaze B2"
provider: "backblaze-b2"
endpoint: "https://s3.us-west-004.backblazeb2.com"
region: "us-west-004"
credentials:
access_key_id: "YOUR_B2_KEY_ID"
secret_access_key: "YOUR_B2_APP_KEY"
limits:
storage_gb: 500
egress_gb_per_month: -1
requests_per_month: -1
enabled: false
# ── Cloudflare R2 ─────────────────────────────────────────────────────────
# No egress fees. Native CDN integration. Good for user-facing content.
- id: "r2-primary"
name: "Cloudflare R2"
provider: "cloudflare-r2"
endpoint: "https://YOUR_CLOUDFLARE_ACCOUNT_ID.r2.cloudflarestorage.com"
region: "auto"
credentials:
access_key_id: "YOUR_R2_ACCESS_KEY"
secret_access_key: "YOUR_R2_SECRET_KEY"
limits:
storage_gb: 1000
egress_gb_per_month: -1 # R2 has no egress charges
requests_per_month: -1
enabled: false
# ── Wasabi ────────────────────────────────────────────────────────────────
# Flat-rate pricing, no egress fees, no API request charges.
# Regions: us-east-1, us-east-2, us-west-1, eu-central-1, eu-west-1, ap-northeast-1
- id: "wasabi-eu"
name: "Wasabi EU"
provider: "wasabi"
endpoint: "https://s3.eu-central-1.wasabisys.com"
region: "eu-central-1"
credentials:
access_key_id: "YOUR_WASABI_KEY"
secret_access_key: "YOUR_WASABI_SECRET"
limits:
storage_gb: -1
egress_gb_per_month: -1
requests_per_month: -1
enabled: false
# ── MinIO (self-hosted) ───────────────────────────────────────────────────
# Your own private object store on bare metal, Kubernetes, or a VPS.
# Use multiple MinIO accounts for geographic distribution or private redundancy.
- id: "minio-private"
name: "MinIO — Private DC"
provider: "minio"
endpoint: "http://minio.internal:9000"
region: "us-east-1"
credentials:
access_key_id: "minioadmin"
secret_access_key: "minioadmin"
limits:
storage_gb: -1
egress_gb_per_month: -1
requests_per_month: -1
enabled: false
# ── Storj ─────────────────────────────────────────────────────────────────
# Decentralised, end-to-end encrypted. Good for privacy-sensitive data.
- id: "storj-main"
name: "Storj"
provider: "storj"
endpoint: "https://gateway.storjshare.io"
region: "global"
credentials:
access_key_id: "YOUR_STORJ_ACCESS_KEY"
secret_access_key: "YOUR_STORJ_SECRET_KEY"
limits:
storage_gb: 150
egress_gb_per_month: 150
requests_per_month: -1
enabled: false
# ── Oracle Cloud Object Storage ───────────────────────────────────────────
# Good for workloads already on OCI. Replace NAMESPACE and REGION below.
- id: "oracle-main"
name: "Oracle Cloud"
provider: "oracle-cloud"
endpoint: "https://YOUR_NAMESPACE.compat.objectstorage.us-phoenix-1.oraclecloud.com"
region: "us-phoenix-1"
credentials:
access_key_id: "YOUR_ORACLE_ACCESS_KEY"
secret_access_key: "YOUR_ORACLE_SECRET_KEY"
limits:
storage_gb: 200
egress_gb_per_month: 50
requests_per_month: -1
enabled: false
# ── iDrive e2 ─────────────────────────────────────────────────────────────
# S3-compatible, no egress fees, competitive pricing.
- id: "idrive-us"
name: "iDrive e2"
provider: "idrive-e2"
endpoint: "https://YOUR_ENDPOINT.e2.idrivee2-XX.com"
region: "us-east-1"
credentials:
access_key_id: "YOUR_IDRIVE_KEY"
secret_access_key: "YOUR_IDRIVE_SECRET"
limits:
storage_gb: 500
egress_gb_per_month: -1
requests_per_month: -1
enabled: false