Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
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
13b3488a
authored
May 13, 2013
by
Bach Dániel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
celery: code formatting
parent
31b28ef0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
miscellaneous/celery/opennebula_celery.py
+4
-4
No files found.
miscellaneous/celery/opennebula_celery.py
View file @
13b3488a
...
...
@@ -5,7 +5,7 @@ from celery import Celery, task
import
time
,
re
import
socket
import
sys
import
tempfile
,
os
,
stat
,
re
,
base64
,
struct
,
logging
import
tempfile
,
os
,
stat
,
re
,
base64
,
struct
,
logging
from
celery.contrib
import
rdb
...
...
@@ -85,7 +85,7 @@ def t(name, instance_type, disk_id, network_id, ctx):
from
xml.dom.minidom
import
parse
,
parseString
try
:
x
=
parseString
(
out
)
return
{
return
{
'one_id'
:
int
(
x
.
getElementsByTagName
(
"ID"
)[
0
]
.
childNodes
[
0
]
.
nodeValue
),
'interfaces'
:
[
{
...
...
@@ -107,7 +107,7 @@ def t(one_id, new_img):
@task
(
name
=
"one.tasks.UpdateDiskTask"
)
def
t
():
f
=
tempfile
.
NamedTemporaryFile
(
delete
=
False
)
f
=
tempfile
.
NamedTemporaryFile
(
delete
=
False
)
f
.
close
()
out
=
''
proc
=
subprocess
.
Popen
([
"/opt/occi.sh storage list >
%
s"
%
f
.
name
],
...
...
@@ -132,7 +132,7 @@ def t():
@task
(
name
=
"one.tasks.UpdateNetworkTask"
)
def
t
():
f
=
tempfile
.
NamedTemporaryFile
(
delete
=
False
)
f
=
tempfile
.
NamedTemporaryFile
(
delete
=
False
)
f
.
close
()
out
=
''
proc
=
subprocess
.
Popen
([
"/opt/occi.sh network list >
%
s"
%
f
.
name
],
...
...
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