Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic generated folders make it impossible to run different playbooks in multithreaded environment. #1143

Open
joaopfg opened this issue Oct 12, 2022 · 3 comments
Labels
needs_verified Issue needs to be verified

Comments

@joaopfg
Copy link

joaopfg commented Oct 12, 2022

The automatic generated folders (artifacts, inventory and project) make it impossible to run different playbooks (with ansible-runner) in different threads.

I can of course remove these folders before and after every command but it doesn't solve the problem when two commands are run almost at the same time.

Is there some work around for this ?

Also, I don't see the reason for these folders to be dumped into the filesystem. Couldn't they be stored as python objects and carried through the code ? Is there a deeper reason for them to be dumped into the filesystem ?

@github-actions github-actions bot added the needs_triage New item that needs to be triaged label Oct 12, 2022
@eqrx eqrx added needs_verified Issue needs to be verified and removed needs_triage New item that needs to be triaged labels Nov 1, 2022
@urbanchef
Copy link

Any updates on this?

@joaopfg
Copy link
Author

joaopfg commented Nov 17, 2022

@urbanchef The work around I implemented in my code is to generate these folders with names in a one to one correspondence with the thread that generated them. Like this, I can manage their lifecycle in each thread. Ugly solution though. I hope someone gets inspired to make a PR getting rid of these folders. I don't have time to dig deeper into that now.

@urbanchef
Copy link

FYI, I create a separate private_data_dir for each playbook run given that project_dir remains the same. I delete private_data_dir some time after. All the details I mentioned here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs_verified Issue needs to be verified
Projects
None yet
Development

No branches or pull requests

3 participants