|
|
@ -7,13 +7,17 @@ lPyOpenRPASourceFolderPathStr = r"..\Sources" # Path for test pyOpenRPA package
|
|
|
|
if lPyOpenRPASourceFolderPathStr != "": sys.path.insert(0,os.path.abspath(os.path.join(lPyOpenRPASourceFolderPathStr))) # Path for test pyOpenRPA package
|
|
|
|
if lPyOpenRPASourceFolderPathStr != "": sys.path.insert(0,os.path.abspath(os.path.join(lPyOpenRPASourceFolderPathStr))) # Path for test pyOpenRPA package
|
|
|
|
|
|
|
|
|
|
|
|
from pyOpenRPA.Agent import __Agent__
|
|
|
|
from pyOpenRPA.Agent import __Agent__
|
|
|
|
|
|
|
|
from pyOpenRPA.Tools import CrossOS
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if CrossOS.IS_WINDOWS_BOOL: lPortInt = 80
|
|
|
|
|
|
|
|
if CrossOS.IS_LINUX_BOOL: lPortInt = 1024
|
|
|
|
gUserNameUpperStr = getpass.getuser().upper()
|
|
|
|
gUserNameUpperStr = getpass.getuser().upper()
|
|
|
|
if __name__ == "__main__": # New init way
|
|
|
|
if __name__ == "__main__": # New init way
|
|
|
|
gSettings = {
|
|
|
|
gSettings = {
|
|
|
|
"OrchestratorDict":{
|
|
|
|
"OrchestratorDict":{
|
|
|
|
"IsHTTPSBool": False, # True - if server is secured HTTPS, False - if server is not secured HTTP
|
|
|
|
"IsHTTPSBool": False, # True - if server is secured HTTPS, False - if server is not secured HTTP
|
|
|
|
"HostStr":"127.0.0.1",
|
|
|
|
"HostStr":"127.0.0.1",
|
|
|
|
"PortInt":80,
|
|
|
|
"PortInt":lPortInt,
|
|
|
|
"SuperTokenStr":"1992-04-03-0643-ru-b4ff-openrpa52zzz", # Access token to Orchestrator
|
|
|
|
"SuperTokenStr":"1992-04-03-0643-ru-b4ff-openrpa52zzz", # Access token to Orchestrator
|
|
|
|
},
|
|
|
|
},
|
|
|
|
"O2ADict":{
|
|
|
|
"O2ADict":{
|
|
|
@ -57,7 +61,7 @@ if __name__ == "__main__": # New init way
|
|
|
|
lL.setLevel(logging.INFO)
|
|
|
|
lL.setLevel(logging.INFO)
|
|
|
|
# create the logging file handler
|
|
|
|
# create the logging file handler
|
|
|
|
mRobotLoggerFH = logging.FileHandler(
|
|
|
|
mRobotLoggerFH = logging.FileHandler(
|
|
|
|
"Logs\\" + gUserNameUpperStr + "_" + datetime.datetime.now().strftime("%Y_%m_%d") + ".log")
|
|
|
|
os.path.normpath("Logs\\" + gUserNameUpperStr + "_" + datetime.datetime.now().strftime("%Y_%m_%d") + ".log"))
|
|
|
|
mRobotLoggerFormatter = logging.Formatter('%(asctime)s - %(levelname)s - %(message)s')
|
|
|
|
mRobotLoggerFormatter = logging.Formatter('%(asctime)s - %(levelname)s - %(message)s')
|
|
|
|
mRobotLoggerFH.setFormatter(mRobotLoggerFormatter)
|
|
|
|
mRobotLoggerFH.setFormatter(mRobotLoggerFormatter)
|
|
|
|
# add handler to logger object
|
|
|
|
# add handler to logger object
|
|
|
|