Yep that's correct, the exec_command function doesn't no or care about what
it is executing, it just has the command to run passed in as cmd and option
input data to send over the stdin pipe. It's up to the caller of
exec_command to make sure the command that it wants to run accepts input
data
Awesome, thanks for the brief explanation. So correct me if I'm wrong, func
exec_command is the one which does the pipeliinig execution , which is then
accepted by $input via and then call execwrapper scriptblock ?
On Friday, August 16, 2019 at 2:40:57 AM UTC+5:30, Jordan Borean wrote:
>
> Hi
>
Jordan,
Worked like a dream! I changed the module to win_command.
Many thanks for your help!
Regards
Chris
On Friday, August 16, 2019 at 12:03:45 PM UTC+1, Jordan Borean wrote:
>
> That’s my bad, when you quote the string and want to execute it you need
> to add the call operator like:
>
>
Oh you're right, I have had a slightly different syntax.
It is working now as you told me, we can close down the discussion.
Thank you for helping me out.
Best regards
Lucas
On Friday, August 16, 2019 at 12:35:39 PM UTC+2, Ganesh Nalawade wrote:
>
> The task input seems to be wrong. Value of
That’s my bad, when you quote the string and want to execute it you need to add
the call operator like:
- raw: ‘&” C:\Program Files\... “‘
The alternative is to use win_command with the setup you have right now.
--
You received this message because you are subscribed to the Google Groups
The task input seems to be wrong. Value of “commands” should be dictionary.
Check the earlier mail for expected task input
On Fri, 16 Aug 2019 at 3:13 PM, Lucas Möller
wrote:
> Just that prompt, answer are noarguments of eric_eccli, here is the output:
>
> "changed": false,
>
Just that prompt, answer are noarguments of eric_eccli, here is the output:
"changed": false,
"invocation": {
"module_args": {
"answer": [
"y"
],
"commands": "save configuration",
"prompt": [
"(y/n)"
Yes please raise a Github issue.
Based on code eric_eccli_commnad module should support prompt when the
value of “commands” option is list of dictionary. What is the error you see
with eric_eccli_command module.
On Fri, 16 Aug 2019 at 2:01 PM, Lucas Möller
wrote:
> Ok I have now checked the
Sorry, just to add to the previous post, the yaml is now as follows:-
- name: Installing the license
raw: '"C:\Program Files\IBM\SQLLIB\BIN\db2licm" -a "{{ temp_area }}\{{
db2_lic_file }}"'
On Thursday, August 15, 2019 at 5:08:28 PM UTC+1, Chris Jackson wrote:
>
>
> Hi all,
>
> Tearing my
Thankls for the responses so far.
Getting a different error now after applying your suggestion Jordan (so
positive)
"stderr_lines": [
"At line:1 char:43",
"+ \"C:\\Program Files\\IBM\\SQLLIB\\BIN\\db2licm\" -a
\"C:\\Users\\ADMINI~1\\AppDa ...",
"+
Ok I have now checked the python code and commented the argument newline
out (lib/ansible/modules/network/cli/cli_command.py: Line 147).
It is seems to work now.
But there is then an issue with the newline parameter on the type of
network devices.
If anybody does not have a better solution or
Thank you for the information.
eric_eccli_command has actually no option for prompts.
cli_command is then the way to go but there is another issue with that,
which seems not to be related to the input in the playbook, but the output
from the device:
"changed": false,
"invocation": {
Try with below task. The prompt option is a regex value to match the
expected terminal prompt after executing the command.
- name: save configuration to flash memory
eric_eccli_command:
commands:
- command: save configuration
prompt:
answer: 'y'
OR
- name: save
13 matches
Mail list logo