Commit f57a41cc authored by Łukasz Nowak's avatar Łukasz Nowak

Simplify imports and make them diff friendly.

parent f3a14222
......@@ -24,8 +24,11 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
##############################################################################
import slapos.slap, subprocess, os, time
from xml_marshaller import xml_marshaller
import os
import slapos.slap
import subprocess
import time
import xml_marshaller
class SlapOSControler(object):
......@@ -60,7 +63,7 @@ class SlapOSControler(object):
if not os.path.exists(partition_path):
os.mkdir(partition_path)
os.chmod(partition_path, 0750)
computer.updateConfiguration(xml_marshaller.dumps({
computer.updateConfiguration(xml_marshaller.xml_marshaller.dumps({
'address': config['ipv4_address'],
'instance_root': config['instance_root'],
'netmask': '255.255.255.255',
......
......@@ -24,13 +24,16 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
##############################################################################
import os, xmlrpclib, time
import os
import pprint
import signal
import socket
import subprocess
import sys
import socket
import pprint
from SlapOSControler import SlapOSControler
import time
import xmlrpclib
import SlapOSControler
class SubprocessError(EnvironmentError):
def __init__(self, status_dict):
......@@ -226,7 +229,7 @@ branch = %(branch)s
updater.checkout()
# Now prepare the installation of SlapOS and create instance
slapos_controler = SlapOSControler(config,
slapos_controler = SlapOSControler.SlapOSControler(config,
process_group_pid_set=process_group_pid_set, log=log)
for method_name in ("runSoftwareRelease", "runComputerPartition"):
stdout, stderr = getInputOutputFileList(config, method_name)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment