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

Concurrency issues with the temporary packages & lock files #47

Open
Nh640 opened this issue Feb 24, 2023 · 3 comments
Open

Concurrency issues with the temporary packages & lock files #47

Nh640 opened this issue Feb 24, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@Nh640
Copy link

Nh640 commented Feb 24, 2023

Hello everybody,

I've come across with an issue on a Linux server where multiple users are using the Platform.sh CLI utility. When two or more of them try to use its commands simultaneously, only one of them gets the lock and temporary files ownership, so that user is the only one that is able to use the utility. The problem here is that the same temporary folder is used for everybody (/tmp), as it is specified in the code:

Is it possible to set a temporary path related to the user that is executing the utility?

Thanks a lot.

@akalipetis
Copy link
Member

Thanks for the report @Nh640 - this is indeed a very interesting issue that we haven't thought of. We'll probably add the user ID in the path there as well to fix the issue.

Have you tried any workarounds? In theory, you could set a different TMP_DIR for each user, but that's definitely not ideal.

What's the use case of multiple users using the CLI on the same server btw? Mostly asking to see what other use cases we could potentially cover.

@akalipetis akalipetis added the bug Something isn't working label Feb 24, 2023
@Nh640
Copy link
Author

Nh640 commented Feb 24, 2023

Thanks for the suggestion, I've tried to find a workaround for the problem but I didn't think about changing TMP_DIR. Indeed it should do the trick for the moment.

I give support to a small team of developers that connect the IDEs installed on their laptops to a remote server where they have all the tools they need to build & deploy their code. One of these tools is Platform.sh CLI.

@akalipetis
Copy link
Member

Thanks a lot, @Nh640 for getting back to us. This seems like a solid use case and indeed if you use the CLI from multiple users this might pose issues. I'll leave this open so that we can make sure the CLI can be run without issues from multiple users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants