You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First of all thanks for creating this! I have often speculated about the possibility of using variable as a file in Ansible (and according to my google search so do others).
As lookups happen on localhost, have looked into if and how it would be possible to get the same result on a remote host?
I guess it would have to happen either by abusing the lookup function somehow or perhaps as a filter, since those are the only two ways that one can call functions in Ansible as a part of a string/variable. Either way it looks like the solution would involve some creative hacking.
The text was updated successfully, but these errors were encountered:
Why don't you simply use ansible.builtin.copy? In that case you don't even need all this demo collection as you can simply pass the variable in content. And then you just have to use that file wherever it is needed and possibly clean it up once done. Or am I misinterpreting your expectation?
First of all thanks for creating this! I have often speculated about the possibility of using variable as a file in Ansible (and according to my google search so do others).
As lookups happen on localhost, have looked into if and how it would be possible to get the same result on a remote host?
I guess it would have to happen either by abusing the lookup function somehow or perhaps as a filter, since those are the only two ways that one can call functions in Ansible as a part of a string/variable. Either way it looks like the solution would involve some creative hacking.
The text was updated successfully, but these errors were encountered: