From: Sandrine Avakian Date: Wed, 18 Jan 2012 13:41:47 +0000 (+0100) Subject: Tony fix to the sfa- start bug when aggregates.xml holds peer information . X-Git-Tag: sfa-2.1-24~3^2~232 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;ds=sidebyside;h=8039d1a8f8dcfe98e98d1879e1cd6b55efd31319;p=sfa.git Tony fix to the sfa- start bug when aggregates.xml holds peer information . --- diff --git a/sfa/server/sfa-start.py b/sfa/server/sfa-start.py index 0c2c0a2a..73c467d6 100755 --- a/sfa/server/sfa-start.py +++ b/sfa/server/sfa-start.py @@ -44,6 +44,7 @@ from sfa.trust.gid import GID from sfa.server.sfaapi import SfaApi from sfa.server.registry import Registries from sfa.server.aggregate import Aggregates +from sfa.client.return_value import ReturnValue # after http://www.erlenstar.demon.co.uk/unix/faq_2.html def daemon(): @@ -102,8 +103,8 @@ def install_peer_certs(server_key_file, server_cert_file): if 'sfa' not in server_version: logger.info("get_trusted_certs: skipping non sfa aggregate: %s" % new_hrn) continue - - trusted_gids = interface.get_trusted_certs() + trusted_gids = ReturnValue.get_value(interface.get_trusted_certs()) + #trusted_gids = interface.get_trusted_certs() print>>sys.stderr, " \r\n \r\n \t=============================================== install_peer_certs TRUSTED_GIDS %s " %(trusted_gids) if trusted_gids: #and not isinstance(trusted_gids,list): @@ -118,8 +119,8 @@ def install_peer_certs(server_key_file, server_cert_file): message += "unable to install trusted gid for %s" % \ (new_hrn) print>>sys.stderr, " \r\n \r\n \t=============================================== install_peer_certs message %s " %(message) - gid = GID(string=trusted_gids[0]) - #gid = GID(string=trusted_gid['value'][0]) + #gid = GID(string=trusted_gids[0]) + gid = GID(string=trusted_gid) print>>sys.stderr, " \r\n \r\n \t=============================================== install_peer_certs gid %s " %(gid) peer_gids.append(gid) if gid.get_hrn() == new_hrn: