Ansible is setting Windows environment variables

We’re seeing some strange behaviour where it seems like Powershell scripts executed by Ansible are having their variables written to the system as environment variables as opposed to temporary session variables. The same scripts run through Jenkins don’t write to ENV, so it seems like Ansible is causing this behaviour.

Any ideas of what the cause/solution might be? We aren’t explicitly creating Windows environment variables through Ansible.

Thanks.

  • Alek

You need to share more details, can you share your playbooks, steps to replicate what you are seeing. From what you have described this could be anything and you need to narrow it down some more so we can help you.