implement proc type in /instance/resources

This commit is contained in:
2023-06-14 04:49:43 +00:00
parent 825b11cd56
commit 17837fbc29
3 changed files with 46 additions and 18 deletions

View File

@@ -1,37 +1,45 @@
{
"application": {
"pveAPI": "https://pve.mydomain/api2/json",
"pveAPI": "https://pve.mydoamin/api2/json",
"pveAPIToken": {
"user": "proxmoxaas-api",
"realm": "pve",
"id": "token",
"uuid": "secret-key"
"uuid": "token-secret-value"
},
"listenPort": 80,
"hostname": "client.mydomain",
"domain": "mydomain"
},
"resources": {
"cpu": {
"type": "list",
"blacklist": false,
"display": false
},
"cores": {
"type": "numeric",
"multiplier": 1,
"base": 1024,
"compact": false,
"unit": "Cores"
"unit": "Cores",
"display": true
},
"memory": {
"type": "numeric",
"multiplier": 1048576,
"base": 1024,
"compact": true,
"unit": "B"
"unit": "B",
"display": true
},
"swap": {
"type": "numeric",
"multiplier": 1048576,
"base": 1024,
"compact": true,
"unit": "B"
"unit": "B",
"display": true
},
"local": {
"type": "storage",
@@ -44,7 +52,8 @@
"mp",
"sata",
"unused"
]
],
"display": true
},
"cephpl": {
"type": "storage",
@@ -57,20 +66,23 @@
"mp",
"sata",
"unused"
]
],
"display": true
},
"network": {
"type": "network",
"multiplier": 1000000,
"base": 1000,
"compact": true,
"unit": "B/s"
"unit": "B/s",
"display": true
}
},
"users": {
"exampleuser@realm": {
"exampleuser@authrealm": {
"resources": {
"max": {
"cpu": ["kvm64", "host"],
"cores": 0,
"memory": 0,
"swap": 0,
@@ -80,16 +92,16 @@
}
},
"nodes": [
"node-0-id",
"node-1-id"
"node1",
"node2"
],
"instances": {
"vmid": {
"min": 100,
"max": 199
},
"pool": "examplepool",
"vlan": "100",
"pool": "exampleuserpool",
"vlan": "10",
"templates": {
"lxc": {
"net0": {