Bug #6606
closedNcf loading doesn't work with windows
Description
It produces too long lines.
The patch used to make it work :
diff --git a/techniques/system/common/1.0/promises.st b/techniques/system/common/1.0/promises.st
index d5b2578..1065965 100644
--- a/techniques/system/common/1.0/promises.st
+++ b/techniques/system/common/1.0/promises.st@ -130,11 +130,13
@ bundle common va
windows::
# Windows agent only exists in 3.6 version, so as a shortcut, we can load all files of ncf
# It should be replaced by a proper script, as explained in #5659
- "ncf_common_inputs" slist => splitstring(execresult("c:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -Command \"ls -Path 'c:\Program Files\Rudder\var\ncf\common' -Name *.cf
+ "ncf_common_inputs12" slist => splitstring(execresult("c:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -Command \"get-childitem -Path 'c:\Program Files\Rudder\var\ncf\common
+ "ncf_common_inputs3456" slist => splitstring(execresult("c:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -Command \"get-childitem -Path 'c:\Program Files\Rudder\var\ncf\comm
"ncf_local_inputs" slist => splitstring(execresult("c:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -Command \"ls -Path 'c:\Program Files\Rudder\var\ncf\local' -Name *.cf -R
# ncf_inputs contains all the files of ncf, and ignore the empty lists
"ncf_inputs" slist => {
- "{ncf_common_inputs}",
{ncf_common_inputs12}",
+ "
+ "{ncf_common_inputs3456}",
{ncf_local_inputs}",
"
},
policy => "ifdefined";