-
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathconfig.yaml
402 lines (359 loc) · 12.8 KB
/
config.yaml
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
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
use_local_only: false
start_vmid: 10000
default_storage: local-lvm
default_network: vmbr0
minimum_resources:
cores: 1
memory_mb: 512
regions:
eu-south-1:
availability_zones:
az1:
host: proxmox1.public-fqdn.com # example: public FQDN (access must be secured)
user: root
ssh_password: password
az2:
host: 172.23.0.2 # example: VPN address
user: root
ssh_password: password
az3:
host: proxmox3.local # example: local network
user: root
ssh_password: password
az4:
host: 192.168.0.4 # example: LAN address
user: root
ssh_password: password
eu-central-1:
availability_zones:
pve-rhine:
host: pve-rhine.mydomain.com
user: root
ssh_password: password
pve-alps:
host: pve-alps.mydomain.com
user: root
ssh_password: password
scaling:
host_cpu:
max_threshold: 80 # Maximum percentage of host CPU usage before considering a decrease
min_threshold: 30 # Minimum percentage of host CPU usage before considering an increase
step: 1 # Base increment or decrement of CPU cores on the host
scale_up_multiplier: 1.5 # Multiplier applied to step size when scaling up
scale_down_multiplier: 0.5 # Multiplier applied to step size when scaling down
lxc_cpu:
max_threshold: 80 # Maximum percentage of LXC CPU usage before considering a decrease
min_threshold: 30 # Minimum percentage of LXC CPU usage before considering an increase
step: 1 # Base increment or decrement of CPU cores in the LXC
scale_up_multiplier: 1.5 # Multiplier applied to step size when scaling up
scale_down_multiplier: 0.5 # Multiplier applied to step size when scaling down
host_memory:
max_threshold: 70 # Percentage of total memory on the host before considering a decrease
min_threshold: 40 # Percentage of total memory on the host before considering an increase
step_mb: 256 # Base amount of memory in MB to increase or decrease
scale_up_multiplier: 1.25 # Multiplier applied to step size when scaling up
scale_down_multiplier: 0.75 # Multiplier applied to step size when scaling down
lxc_memory:
max_threshold: 70 # Maximum percentage of LXC memory usage before considering a decrease
min_threshold: 40 # Minimum percentage of LXC memory usage before considering an increase
step_mb: 256 # Base amount of memory in MB to increase or decrease
scale_up_multiplier: 1.25 # Multiplier applied to step size when scaling up
scale_down_multiplier: 0.75 # Multiplier applied to step size when scaling down
host_storage:
max_threshold: 85 # Maximum percentage of storage usage on the host before considering a decrease
min_threshold: 50 # Minimum percentage of storage usage on the host before considering an increase
step_gb: 10 # Base increment or decrement of storage in GB
scale_up_multiplier: 1.5 # Multiplier applied to step size when scaling up
scale_down_multiplier: 0.5 # Multiplier applied to step size when scaling down
lxc_storage:
max_threshold: 85 # Maximum percentage of storage usage in the LXC before considering a decrease
min_threshold: 50 # Minimum percentage of storage usage in the LXC before considering an increase
step_gb: 10 # Base increment or decrement of storage in GB
scale_up_multiplier: 1.5 # Multiplier applied to step size when scaling up
scale_down_multiplier: 0.5 # Multiplier applied to step size when scaling down
limits:
min_memory_mb: 512 # Minimum allowed memory for any LXC container
max_memory_mb: 32768 # Maximum allowed memory for any LXC container
min_cpu_cores: 1 # Minimum allowed CPU cores for any LXC container
max_cpu_cores: 16 # Maximum allowed CPU cores for any LXC container
min_storage_gb: 10 # Minimum allowed storage for any LXC container
max_storage_gb: 1024 # Maximum allowed storage for any LXC container
general:
scaling_interval: 5 # Interval in minutes to check for resource adjustments
notify_user: true # Notify user via CLI output when scaling adjustments are made
dry_run: false # If true, simulate scaling adjustments without applying changes
scaling_log_level: DEBUG # Log level for scaling operations (DEBUG, INFO, WARN, ERROR)
use_custom_scaling_algorithms: false # Enable if custom scaling algorithms are implemented
security:
discovery:
proxmox_timeout: 2
lxc_timeout: 2
discovery_methods: ['ping']
max_parallel_workers: 10 # Maximum number of parallel workers
instance_sizes:
# Generic
micro:
memory: 512
cpulimit: 1
storage: local-lvm:4
small:
memory: 1024
cpulimit: 1
storage: local-lvm:8
mid:
memory: 2048
cpulimit: 2
storage: local-lvm:16
large:
memory: 4096
cpulimit: 2
storage: local-lvm:32
x-large:
memory: 8192
cpulimit: 4
storage: local-lvm:64
xx-large:
memory: 16384
cpulimit: 8
storage: local-lvm:128
# Open-Source Self-Hosted Applications with Abstract Roles
lws-minio:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: MinIO for object storage.
lws-postgres:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:40 # 40 GB of storage
# Example: PostgreSQL for relational database.
lws-mysql:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:40 # 40 GB of storage
# Example: MySQL for relational database.
lws-nosql:
memory: 8192 # 8 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: MongoDB for NoSQL database.
lws-cdn:
memory: 1024 # 1 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:10 # 10 GB of storage
# Example: Caddy for reverse proxy and CDN.
lws-metrics-monitoring:
memory: 2048 # 2 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:20 # 20 GB of storage
# Example: Prometheus for metrics and monitoring.
lws-metrics-visualization:
memory: 2048 # 2 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:20 # 20 GB of storage
# Example: Grafana for data visualization.
lws-mq:
memory: 2048 # 2 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:20 # 20 GB of storage
# Example: Apache ActiveMQ for messaging queues.
lws-firewall:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:20 # 20 GB of storage
# Example: OPNsense for firewall and routing.
lws-search-analytics:
memory: 8192 # 8 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: OpenSearch for search and analytics.
lws-serverless:
memory: 2048 # 2 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:20 # 20 GB of storage
# Example: OpenFaaS for serverless functions.
lws-email:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:40 # 40 GB of storage
# Example: Mailcow for email management.
lws-machine-learning:
memory: 8192 # 8 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: Hugging Face Transformers for machine learning models.
lws-identity-management:
memory: 8192 # 8 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: Keycloak for identity and access management.
lws-file-storage:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: Nextcloud for file storage and collaboration.
lws-data-warehouse:
memory: 16384 # 16 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:100 # 100 GB of storage
# Example: ClickHouse for data warehousing.
lws-messaging-broker:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:40 # 40 GB of storage
# Example: RabbitMQ for messaging broker.
lws-code-server:
memory: 2048 # 2 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:20 # 20 GB of storage
# Example: Coder or code-server for online development environment.
lws-log-aggregation:
memory: 8192 # 8 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: Loki for log aggregation.
lws-container-registry:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: Harbor for container registry.
lws-web:
memory: 2048 # 2 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:20 # 20 GB of storage
# Example: Nginx for web server.
lws-load-balancer:
memory: 2048 # 2 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:20 # 20 GB of storage
# Example: HAProxy for load balancing.
lws-redis:
memory: 2048 # 2 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:10 # 10 GB of storage
# Example: Redis for in-memory caching.
lws-vpn:
memory: 2048 # 2 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:10 # 10 GB of storage
# Example: OpenVPN for VPN server.
lws-backup-system:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:50 # 50 GB of storage
# Example: Restic or Bacula for backup solutions.
lws-static-site-generator:
memory: 2048 # 2 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:10 # 10 GB of storage
# Example: Hugo for static site generation.
lws-dns:
memory: 1024 # 1 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:10 # 10 GB of storage
# Example: PowerDNS for DNS management.
# General Purpose Instances: balance of compute, memory, and networking resources.
t2-pico:
memory: 512 # 1 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:8 # 8 GB of storage
t2-micro:
memory: 1024 # 1 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:8 # 8 GB of storage
t2-small:
memory: 2048 # 2 GB
cpulimit: 1 # 1 vCPU
storage: local-lvm:20 # 20 GB of storage
t2-medium:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:40 # 40 GB of storage
m5-large:
memory: 8192 # 8 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:50 # 50 GB of storage
m5-xlarge:
memory: 16384 # 16 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:100 # 100 GB of storage
m5-2xlarge:
memory: 32768 # 32 GB
cpulimit: 8 # 8 vCPUs
storage: local-lvm:200 # 200 GB of storage
# Compute Optimized Instances: applications that benefit from high-performance processors.
c5-large:
memory: 4096 # 4 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:50 # 50 GB of storage
c5-xlarge:
memory: 8192 # 8 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:100 # 100 GB of storage
c5-2xlarge:
memory: 16384 # 16 GB
cpulimit: 8 # 8 vCPUs
storage: local-lvm:200 # 200 GB of storage
c5-4xlarge:
memory: 32768 # 32 GB
cpulimit: 16 # 16 vCPUs
storage: local-lvm:400 # 400 GB of storage
# Memory Optimized Instances: memory-intensive applications like databases.
r5-large:
memory: 16384 # 16 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:100 # 100 GB of storage
r5-xlarge:
memory: 32768 # 32 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:200 # 200 GB of storage
r5-2xlarge:
memory: 65536 # 64 GB
cpulimit: 8 # 8 vCPUs
storage: local-lvm:400 # 400 GB of storage
x1e-xlarge:
memory: 65536 # 64 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:200 # 200 GB of storage
x1e-2xlarge:
memory: 131072 # 128 GB
cpulimit: 8 # 8 vCPUs
storage: local-lvm:400 # 400 GB of storage
x1e-4xlarge:
memory: 262144 # 256 GB
cpulimit: 16 # 16 vCPUs
storage: local-lvm:800 # 800 GB of storage
# Storage Optimized Instances: high, sequential read and write access to very large datasets on local storage.
i3-large:
memory: 15360 # 15 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:500 # 500 GB of storage
i3-xlarge:
memory: 30720 # 30 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:1000 # 1 TB of storage
i3-2xlarge:
memory: 61440 # 60 GB
cpulimit: 8 # 8 vCPUs
storage: local-lvm:2000 # 2 TB of storage
i3-4xlarge:
memory: 122880 # 120 GB
cpulimit: 16 # 16 vCPUs
storage: local-lvm:4000 # 4 TB of storage
# GPU Instances: machine learning, graphics processing, or general-purpose GPU computing.
p3-large:
memory: 15360 # 15 GB
cpulimit: 2 # 2 vCPUs
storage: local-lvm:100 # 100 GB of storage
p3-xlarge:
memory: 30720 # 30 GB
cpulimit: 4 # 4 vCPUs
storage: local-lvm:200 # 200 GB of storage
p3-2xlarge:
memory: 61440 # 60 GB
cpulimit: 8 # 8 vCPUs
storage: local-lvm:400 # 400 GB of storage
p3-8xlarge:
memory: 245760 # 240 GB
cpulimit: 32 # 32 vCPUs
storage: local-lvm:1600 # 1.6 TB of storage