Commit 69aa6878 authored by Yingjie Xu's avatar Yingjie Xu

Simplify instance_path representation.

parent 9f3d086c
...@@ -570,6 +570,8 @@ class Slapgrid(object): ...@@ -570,6 +570,8 @@ class Slapgrid(object):
# Process Computer Partitions # Process Computer Partitions
clean_run = True clean_run = True
for computer_partition in self.getComputerPartitionList(): for computer_partition in self.getComputerPartitionList():
instance_path = os.path.join(self.instance_root,
computer_partition.getId())
computer_partition_id = computer_partition.getId() computer_partition_id = computer_partition.getId()
try: try:
software_url = computer_partition.getSoftwareRelease().getURI() software_url = computer_partition.getSoftwareRelease().getURI()
...@@ -579,8 +581,7 @@ class Slapgrid(object): ...@@ -579,8 +581,7 @@ class Slapgrid(object):
getSoftwareUrlHash(software_url)) getSoftwareUrlHash(software_url))
local_partition = Partition( local_partition = Partition(
software_path=software_path, software_path=software_path,
instance_path=os.path.join(self.instance_root, instance_path=instance_path),
computer_partition.getId()),
supervisord_partition_configuration_path=os.path.join( supervisord_partition_configuration_path=os.path.join(
self.supervisord_configuration_directory, '%s.conf' % self.supervisord_configuration_directory, '%s.conf' %
computer_partition_id), computer_partition_id),
......
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