You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by pq...@apache.org on 2010/03/24 07:38:59 UTC
svn commit: r926950 - /incubator/libcloud/trunk/libcloud/drivers/softlayer.py
Author: pquerna
Date: Wed Mar 24 06:38:59 2010
New Revision: 926950
URL: http://svn.apache.org/viewvc?rev=926950&view=rev
Log:
dont' set node.state to a random int, at least set it to the correct type
Modified:
incubator/libcloud/trunk/libcloud/drivers/softlayer.py
Modified: incubator/libcloud/trunk/libcloud/drivers/softlayer.py
URL: http://svn.apache.org/viewvc/incubator/libcloud/trunk/libcloud/drivers/softlayer.py?rev=926950&r1=926949&r2=926950&view=diff
==============================================================================
--- incubator/libcloud/trunk/libcloud/drivers/softlayer.py (original)
+++ incubator/libcloud/trunk/libcloud/drivers/softlayer.py Wed Mar 24 06:38:59 2010
@@ -19,7 +19,7 @@ Softlayer driver
import xmlrpclib
import libcloud
-from libcloud.types import Provider, InvalidCredsException
+from libcloud.types import Provider, InvalidCredsException, NodeState
from libcloud.base import NodeDriver, Node, NodeLocation
DATACENTERS = {
@@ -111,7 +111,8 @@ class SoftLayerNodeDriver(NodeDriver):
return Node(
id=host['id'],
name=host['hostname'],
- state=host['statusId'],
+ # TODO: figure out how to get the correct power state
+ state=NodeState.UNKNOWN,
public_ip=host['primaryIpAddress'],
private_ip=host['primaryBackendIpAddress'],
driver=self