def set_completed(session, computer): WSE_computer = 'W10DTSM18306' port = '1234' print('Creating Proxy for device:Day2_Agent at host: '+WSE_computer+' port: '+port+' device name: Day2_Agent') #Create the Proxy for the dummy components fullport = WSE_computer+':'+port proxy = Proxy(fullport, serialization='json') ping_result = os.system('ping %s -n 1' % (WSE_computer,)) if ping_result: print('Host '+WSE_computer+' Not Found') # LAN WAKE UP CALL GOES HERE else: print('Host '+WSE_computer+' Found') initiated = True try: proxy.signal_completed(session, computer) print('signaled complete sucessfully') except Exception as E: print('failed to signal complete') print(E)
def get_processing_assitant_proxy(): computer = os.environ['COMPUTERNAME'] port = '1212' print('Creating Proxy for device:Day2_Agent at host: '+computer+' port: '+port+' device name: Day2_Agent') #Create the Proxy for the dummy components fullport = computer+':'+port proxy = Proxy(fullport, serialization='json') ping_result = os.system('ping %s -n 1' % (computer,)) if ping_result: print('Host '+computer+' Not Found') # LAN WAKE UP CALL GOES HERE else: print('Host '+computer+' Found') return proxy