Class: Fog::Volume::OpenStack::V2::Real
- Inherits:
-
Object
- Object
- Fog::Volume::OpenStack::V2::Real
show all
- Includes:
- OpenStack::Core, Real
- Defined in:
- lib/fog/volume/openstack/v2.rb,
lib/fog/volume/openstack/v2/requests/real.rb,
lib/fog/volume/openstack/v2/requests/real_mock.rb,
lib/fog/volume/openstack/v2/requests/list_volumes.rb,
lib/fog/volume/openstack/v2/requests/create_volume.rb,
lib/fog/volume/openstack/v2/requests/create_snapshot.rb,
lib/fog/volume/openstack/v2/requests/get_volume_details.rb,
lib/fog/volume/openstack/v2/requests/get_snapshot_details.rb,
lib/fog/volume/openstack/v2/requests/list_volumes_detailed.rb
Instance Attribute Summary
#auth_token, #auth_token_expiration, #current_tenant, #current_user, #current_user_id, #openstack_cache_ttl, #openstack_domain_id, #openstack_domain_name, #openstack_identity_api_version, #openstack_project_domain, #openstack_project_domain_id, #openstack_project_id, #openstack_user_domain, #openstack_user_domain_id, #unscoped_token
Class Method Summary
collapse
Instance Method Summary
collapse
Methods included from Real
#accept_transfer, #action, #create_backup, #create_transfer, #create_volume_type, #delete_backup, #delete_metadata, #delete_snapshot, #delete_snapshot_metadata, #delete_transfer, #delete_volume, #delete_volume_type, #extend_volume, #get_backup_details, #get_quota, #get_quota_defaults, #get_quota_usage, #get_snapshot_details, #get_transfer_details, #get_volume_details, #get_volume_type_details, #list_backups, #list_backups_detailed, #list_snapshots, #list_snapshots_detailed, #list_transfers, #list_transfers_detailed, #list_volume_types, #list_volumes, #list_volumes_detailed, #list_zones, #replace_metadata, #restore_backup, #set_tenant, #snapshot_action, #update_metadata, #update_quota, #update_snapshot, #update_snapshot_metadata, #update_volume, #update_volume_type
#credentials, #initialize, #reload
Class Method Details
.not_found_class ⇒ Object
153
154
155
|
# File 'lib/fog/volume/openstack/v2.rb', line 153
def self.not_found_class
Fog::Volume::OpenStack::NotFound
end
|
Instance Method Details
#create_snapshot(volume_id, name, description, force = false) ⇒ Object
10
11
12
13
14
15
16
17
18
19
20
21
|
# File 'lib/fog/volume/openstack/v2/requests/create_snapshot.rb', line 10
def create_snapshot(volume_id, name, description, force = false)
data = {
'snapshot' => {
'volume_id' => volume_id,
'name' => name,
'description' => description,
'force' => force.nil? ? false : force
}
}
_create_snapshot(data)
end
|
#create_volume(name, description, size, options = {}) ⇒ Object
8
9
10
11
12
13
14
15
16
17
18
|
# File 'lib/fog/volume/openstack/v2/requests/create_volume.rb', line 8
def create_volume(name, description, size, options = {})
data = {
'volume' => {
'name' => name,
'description' => description,
'size' => size
}
}
_create_volume(data, options)
end
|
#default_endtpoint_type ⇒ Object
157
158
159
|
# File 'lib/fog/volume/openstack/v2.rb', line 157
def default_endtpoint_type
'admin'
end
|
#default_service_type ⇒ Object
161
162
163
|
# File 'lib/fog/volume/openstack/v2.rb', line 161
def default_service_type
%w[volumev2]
end
|