fog-proxmox 0.11.0 → 0.11.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/lib/fog/compute/proxmox/requests/action_server.rb +1 -0
- data/lib/fog/compute/proxmox/requests/clone_server.rb +1 -0
- data/lib/fog/compute/proxmox/requests/create_backup.rb +1 -0
- data/lib/fog/compute/proxmox/requests/create_server.rb +1 -0
- data/lib/fog/compute/proxmox/requests/create_snapshot.rb +3 -1
- data/lib/fog/compute/proxmox/requests/create_spice.rb +1 -0
- data/lib/fog/compute/proxmox/requests/create_term.rb +1 -0
- data/lib/fog/compute/proxmox/requests/create_vnc.rb +1 -0
- data/lib/fog/compute/proxmox/requests/delete_server.rb +1 -0
- data/lib/fog/compute/proxmox/requests/delete_snapshot.rb +3 -1
- data/lib/fog/compute/proxmox/requests/delete_volume.rb +1 -1
- data/lib/fog/compute/proxmox/requests/get_node_statistics.rb +2 -2
- data/lib/fog/compute/proxmox/requests/get_server_config.rb +18 -0
- data/lib/fog/compute/proxmox/requests/get_server_status.rb +21 -0
- data/lib/fog/compute/proxmox/requests/get_snapshot_config.rb +1 -1
- data/lib/fog/compute/proxmox/requests/get_task.rb +1 -1
- data/lib/fog/compute/proxmox/requests/get_vnc.rb +1 -0
- data/lib/fog/compute/proxmox/requests/get_volume.rb +1 -1
- data/lib/fog/compute/proxmox/requests/list_nodes.rb +8 -1
- data/lib/fog/compute/proxmox/requests/list_servers.rb +72 -1
- data/lib/fog/compute/proxmox/requests/list_snapshots.rb +24 -1
- data/lib/fog/compute/proxmox/requests/list_storages.rb +3 -1
- data/lib/fog/compute/proxmox/requests/list_tasks.rb +3 -1
- data/lib/fog/compute/proxmox/requests/list_volumes.rb +3 -1
- data/lib/fog/compute/proxmox/requests/log_task.rb +3 -1
- data/lib/fog/compute/proxmox/requests/migrate_server.rb +1 -1
- data/lib/fog/compute/proxmox/requests/move_disk.rb +1 -1
- data/lib/fog/compute/proxmox/requests/move_volume.rb +1 -1
- data/lib/fog/compute/proxmox/requests/next_vmid.rb +1 -0
- data/lib/fog/compute/proxmox/requests/resize_container.rb +1 -1
- data/lib/fog/compute/proxmox/requests/resize_server.rb +1 -1
- data/lib/fog/compute/proxmox/requests/rollback_snapshot.rb +3 -1
- data/lib/fog/compute/proxmox/requests/status_task.rb +1 -1
- data/lib/fog/compute/proxmox/requests/stop_task.rb +1 -1
- data/lib/fog/compute/proxmox/requests/template_server.rb +1 -0
- data/lib/fog/compute/proxmox/requests/update_server.rb +1 -0
- data/lib/fog/compute/proxmox/requests/update_snapshot.rb +1 -1
- data/lib/fog/proxmox/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ff3b6b71744bd3bdf8b1d94ca042ab16d00918ec61fb061150a547fae82d0877
|
4
|
+
data.tar.gz: c91827f7fc32227d84e927f93c093d8c5722f1e351e333776bbf270b1ece66d1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4988ae1572d65c6ebc3530235c9400e8bb5f3badd1350f442ed013273a576cc13b6e1f74a644b623b1918388b3f54d5ba6e907d2fb933a287e1f24facc5b39c6
|
7
|
+
data.tar.gz: 6177e9300809132e8cc3c0f4c4739a3eabde32d32cd3049eb702044439030298837f823883d24b393be5aa1fe101ed141dcab2417a32f1b7c0bdd72500ec3450
|
data/.gitignore
CHANGED
@@ -23,7 +23,7 @@ module Fog
|
|
23
23
|
class Compute
|
24
24
|
# class Real get_node_statistics request
|
25
25
|
class Real
|
26
|
-
def get_node_statistics(path_params,query_params)
|
26
|
+
def get_node_statistics(path_params, query_params)
|
27
27
|
node = path_params[:node]
|
28
28
|
output = path_params[:output]
|
29
29
|
request(
|
@@ -37,7 +37,7 @@ module Fog
|
|
37
37
|
|
38
38
|
# class Mock get_statistics request
|
39
39
|
class Mock
|
40
|
-
def get_node_statistics; end
|
40
|
+
def get_node_statistics(_path_params, _query_params); end
|
41
41
|
end
|
42
42
|
end
|
43
43
|
end
|
@@ -36,6 +36,24 @@ module Fog
|
|
36
36
|
|
37
37
|
# class Mock get_server_config request
|
38
38
|
class Mock
|
39
|
+
def get_server_config(_path_params)
|
40
|
+
{
|
41
|
+
:onboot => 0,
|
42
|
+
:memory => 512,
|
43
|
+
:ostype => 'l26',
|
44
|
+
:cores => 1,
|
45
|
+
:keyboard => 'en-us',
|
46
|
+
:digest => nil,
|
47
|
+
:smbios1 => nil,
|
48
|
+
:vmgenid => nil,
|
49
|
+
:balloon => 0,
|
50
|
+
:kvm => 0,
|
51
|
+
:cpu => 'cputype=kvm64',
|
52
|
+
:sockets => 1,
|
53
|
+
:bootdisk => 'scsi0',
|
54
|
+
:vga => 'std'
|
55
|
+
}
|
56
|
+
end
|
39
57
|
end
|
40
58
|
end
|
41
59
|
end
|
@@ -36,6 +36,27 @@ module Fog
|
|
36
36
|
|
37
37
|
# class Mock get_server_status request
|
38
38
|
class Mock
|
39
|
+
def get_server_status(_path_params)
|
40
|
+
{
|
41
|
+
:netout => 0,
|
42
|
+
:ha => { 'managed' => 0 },
|
43
|
+
:mem => 0,
|
44
|
+
:vmid => '100',
|
45
|
+
:maxdisk => 8_589_934_592,
|
46
|
+
:diskread => 0,
|
47
|
+
:template => '',
|
48
|
+
:qmpstatus => 'stopped',
|
49
|
+
:diskwrite => 0,
|
50
|
+
:maxmem => 536_870_912,
|
51
|
+
:pid => nil,
|
52
|
+
:uptime => 0,
|
53
|
+
:status => 'stopped',
|
54
|
+
:cpu => 'cputype=kvm64',
|
55
|
+
:cpus => 1,
|
56
|
+
:disk => 0,
|
57
|
+
:netin => 0
|
58
|
+
}
|
59
|
+
end
|
39
60
|
end
|
40
61
|
end
|
41
62
|
end
|
@@ -35,7 +35,78 @@ module Fog
|
|
35
35
|
|
36
36
|
# class Mock list_servers request
|
37
37
|
class Mock
|
38
|
-
def list_servers
|
38
|
+
def list_servers(_options = {})
|
39
|
+
if options[:type] == 'qemu'
|
40
|
+
[
|
41
|
+
{
|
42
|
+
'vmid' => '100',
|
43
|
+
'type' => 'qemu',
|
44
|
+
'node_id' => 'proxmox',
|
45
|
+
'config' => {
|
46
|
+
'vmid' => '100',
|
47
|
+
'description' => nil,
|
48
|
+
'smbios1' => nil,
|
49
|
+
'numa' => 0,
|
50
|
+
'kvm' => 0,
|
51
|
+
'vcpus' => nil,
|
52
|
+
'cores' => 1,
|
53
|
+
'bootdisk' => 'scsi0',
|
54
|
+
'onboot' => 0,
|
55
|
+
'boot' => nil,
|
56
|
+
'agent' => '0',
|
57
|
+
'scsihw' => nil,
|
58
|
+
'sockets' => 1,
|
59
|
+
'memory' => 512,
|
60
|
+
'min_memory' => nil,
|
61
|
+
'shares' => nil,
|
62
|
+
'balloon' => 0,
|
63
|
+
'cpu' => 'cputype=kvm64',
|
64
|
+
'cpulimit' => nil,
|
65
|
+
'cpuunits' => nil,
|
66
|
+
'keyboard' => 'en-us',
|
67
|
+
'vga' => 'std',
|
68
|
+
'storage' => nil,
|
69
|
+
'template' => '',
|
70
|
+
'arch' => nil,
|
71
|
+
'swap' => nil,
|
72
|
+
'hostname' => nil,
|
73
|
+
'nameserver' => nil,
|
74
|
+
'searchdomain' => nil,
|
75
|
+
'password' => nil,
|
76
|
+
'startup' => nil,
|
77
|
+
'console' => nil
|
78
|
+
},
|
79
|
+
'digest' => nil,
|
80
|
+
'maxdisk' => 8_589_934_592,
|
81
|
+
'disk' => 0,
|
82
|
+
'diskwrite' => 0,
|
83
|
+
'diskread' => 0,
|
84
|
+
'uptime' => 0,
|
85
|
+
'netout' => 0,
|
86
|
+
'netin' => 0,
|
87
|
+
'cpu' => 'cputype=kvm64',
|
88
|
+
'cpus' => 1,
|
89
|
+
'template' => '',
|
90
|
+
'status' => 'stopped',
|
91
|
+
'maxcpu' => nil,
|
92
|
+
'mem' => 0,
|
93
|
+
'maxmem' => 536_870_912,
|
94
|
+
'qmpstatus' => 'stopped',
|
95
|
+
'ha' => { 'managed' => 0 },
|
96
|
+
'pid' => nil,
|
97
|
+
'blockstat' => nil,
|
98
|
+
'balloon' => 0,
|
99
|
+
'ballooninfo' => nil,
|
100
|
+
'vmgenid' => nil,
|
101
|
+
'lock' => nil,
|
102
|
+
'maxswap' => nil,
|
103
|
+
'swap' => nil
|
104
|
+
}
|
105
|
+
]
|
106
|
+
else
|
107
|
+
[]
|
108
|
+
end
|
109
|
+
end
|
39
110
|
end
|
40
111
|
end
|
41
112
|
end
|
@@ -36,7 +36,30 @@ module Fog
|
|
36
36
|
|
37
37
|
# class Mock list_snapshots request
|
38
38
|
class Mock
|
39
|
-
def list_snapshots
|
39
|
+
def list_snapshots(_path_params)
|
40
|
+
[
|
41
|
+
{
|
42
|
+
'name' => 'snapshot1',
|
43
|
+
'description' => 'latest snapshot',
|
44
|
+
'snaptime' => 1_578_057_452,
|
45
|
+
'vmstate' => 0,
|
46
|
+
'node_id' => 'proxmox',
|
47
|
+
'server_id' => '100',
|
48
|
+
'server_type' => 'qemu',
|
49
|
+
'vmgenid' => nil
|
50
|
+
},
|
51
|
+
{
|
52
|
+
'name' => 'snapshot2',
|
53
|
+
'description' => 'latest snapshot2',
|
54
|
+
'snaptime' => 1_578_058_452,
|
55
|
+
'vmstate' => 0,
|
56
|
+
'node_id' => 'proxmox',
|
57
|
+
'server_id' => '100',
|
58
|
+
'server_type' => 'qemu',
|
59
|
+
'vmgenid' => nil
|
60
|
+
}
|
61
|
+
]
|
62
|
+
end
|
40
63
|
end
|
41
64
|
end
|
42
65
|
end
|
data/lib/fog/proxmox/version.rb
CHANGED