Closed arjanhak closed 7 months ago
@arjanhak I've raised a PR which I believe should fix this. Delegating to localhost is, I believe, fine to be doing here because we are just templating stuff to munge some variables; however not all of the section was run against localhost so it didn't fully work. It should now with my fix.
Summary
I created a playbook that runs the infra.ee_utilities.ee_builder on a remote host, but I cannot use the ee_create_controller_def as part of the block are wrongfully executed on localhost.
Issue Type
Ansible, Collection, Docker/Podman details
OS / ENVIRONMENT
Desired Behavior
When I have a playbook that runs on a remote machine, I want to use the set_stats module to export the execution environment(s) meta information to the infra.controller_configuration.execution_environments role.
Actual Behavior
Task "Create temporary folder" in roles/ee_builder/tasks/main.yml successfully creates the temporary directory on the remote machine, I can see it there. But the next task "Create execution environment definition file" fails because the directory does not exist on localhost. If the "delegate_to: localhost" had not been there (also for the next task below it) then it would have worked afaik.
STEPS TO REPRODUCE