Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
circlestack
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
131d21d2
authored
Sep 23, 2014
by
Guba Sándor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vm/models: rename resize_disk and fix disk size value
parent
5ff4625d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
circle/vm/models/instance.py
+6
-4
No files found.
circle/vm/models/instance.py
View file @
131d21d2
...
@@ -790,15 +790,17 @@ class Instance(AclBase, VirtualMachineDescModel, StatusModel, OperatedMixin,
...
@@ -790,15 +790,17 @@ class Instance(AclBase, VirtualMachineDescModel, StatusModel, OperatedMixin,
else
:
else
:
raise
raise
def
resize_disk
(
self
,
disk
,
size
,
timeout
=
15
):
def
resize_disk
_live
(
self
,
disk
,
size
,
timeout
=
15
):
try
:
try
:
queue_name
=
self
.
get_remote_queue_name
(
'vm'
,
'slow'
)
queue_name
=
self
.
get_remote_queue_name
(
'vm'
,
'slow'
)
return
vm_task
.
resize_disk
.
apply_async
(
return
vm_task
s
.
resize_disk
.
apply_async
(
args
=
[
self
.
vm_name
,
disk
.
path
,
size
],
args
=
[
self
.
vm_name
,
disk
.
path
,
size
],
queue
=
queue_name
)
.
get
(
timeout
=
timeout
)
queue
=
queue_name
)
.
get
(
timeout
=
timeout
)
except
:
except
:
raise
raise
else
:
disk
.
size
=
size
disk
.
save
()
def
deploy_disks
(
self
):
def
deploy_disks
(
self
):
"""Deploy all associated disks.
"""Deploy all associated disks.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment