diff --git a/contents/winrm-exec.py b/contents/winrm-exec.py index 38602f1..cff2ae5 100644 --- a/contents/winrm-exec.py +++ b/contents/winrm-exec.py @@ -75,7 +75,7 @@ if os.environ.get('RD_JOB_LOGLEVEL') == 'DEBUG': log_level = 'DEBUG' else: - log_level = 'ERROR' + log_level = 'WARNING' ##end @@ -263,8 +263,11 @@ sys.stdout = realstdout sys.stderr = realstderr -if tsk.e_std: - log.error("Execution finished with the following error") +if tsk.stat ==0 and tsk.e_std: + #printing sterr when the exit code is cero + log.warning(tsk.e_std) + +if tsk.stat !=0: log.error(tsk.e_std) sys.exit(1) else: diff --git a/plugin.yaml b/plugin.yaml index ae4d4f6..80a6ff1 100644 --- a/plugin.yaml +++ b/plugin.yaml @@ -1,17 +1,9 @@ name: py-winrm-plugin -rundeckPluginVersion: 2.0 +rundeckPluginVersion: 1.2 author: "@author@" date: "@date@" version: "@version@" url: "@url@" -description: "Python WINRM node executor and file copier" -rundeckCompatibilityVersion: "3.x" -targetHostCompatibility: "all" -license: "Apache 2.0" -tags: - - script - - NodeExecutor - - FileCopier providers: - name: WinRMPython title: WinRM Node Executor Python