Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Fukász Rómeó Ervin
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
A prog2-höz tartozó friss repo anyagok itt elérhetőek:
https://git.iit.bme.hu/
Commit
a4d5963c
authored
Oct 16, 2014
by
Őry Máté
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vm: add clone=False arg to SaveAsTemplateOperation
parent
95f16415
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletions
+3
-1
circle/vm/operations.py
+3
-1
No files found.
circle/vm/operations.py
View file @
a4d5963c
...
...
@@ -637,7 +637,7 @@ class SaveAsTemplateOperation(InstanceOperation):
disk
.
destroy
()
def
_operation
(
self
,
activity
,
user
,
system
,
name
=
None
,
with_shutdown
=
True
,
task
=
None
,
**
kwargs
):
with_shutdown
=
True
,
clone
=
False
,
task
=
None
,
**
kwargs
):
if
with_shutdown
:
try
:
ShutdownOperation
(
self
.
instance
)
.
call
(
parent_activity
=
activity
,
...
...
@@ -687,6 +687,8 @@ class SaveAsTemplateOperation(InstanceOperation):
tmpl
=
InstanceTemplate
(
**
params
)
tmpl
.
full_clean
()
# Avoiding database errors.
tmpl
.
save
()
if
clone
:
tmpl
.
clone_acl
(
self
.
instance
.
template
)
try
:
tmpl
.
disks
.
add
(
*
self
.
disks
)
# create interface templates
...
...
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