Skip to content

Avoid change chmod by using Nette\Utils\FileSystem with pass null on 3rd argument on write - #209

Merged
samsonasik merged 2 commits into
mainfrom
avoid-change-chmod
May 28, 2024
Merged

Avoid change chmod by using Nette\Utils\FileSystem with pass null on 3rd argument on write#209
samsonasik merged 2 commits into
mainfrom
avoid-change-chmod

Conversation

@samsonasik

@samsonasik samsonasik commented May 24, 2024

Copy link
Copy Markdown
Collaborator

@samsonasik

Copy link
Copy Markdown
Collaborator Author

@vasilvestre could you verify this patch? Thank you.


namespace Symplify\EasyCodingStandard\Caching\ValueObject\Storage;

use Nette\Utils\FileSystem as UtilsFileSystem;

@samsonasik samsonasik May 24, 2024

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vasilvestre for manual test, with directly change on vendor, change it with prefixed use statement:

use ECSPrefix202405\Nette\Utils\FileSystem as UtilsFileSystem;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will try soon

@vasilvestre

Copy link
Copy Markdown

It's not working for me, the ownership still changes to root:root despite an original user with UID 1000

@samsonasik

Copy link
Copy Markdown
Collaborator Author

I am not sure why it can change ownership, chaning chmod is what we seen in the past, but ownership is strange as it should not know what new one, it probably related with somewhere on your php setting and executable as user you run.

I suggest to not run on docker as it may be the root of the issue.

I will may still merge it to sync with rector.

@samsonasik

Copy link
Copy Markdown
Collaborator Author

@TomasVotruba I am merging it so we have sync usage with rector ;)

@samsonasik
samsonasik merged commit d82d8ee into main May 28, 2024
@samsonasik
samsonasik deleted the avoid-change-chmod branch May 28, 2024 08:54
@vasilvestre

Copy link
Copy Markdown

I am not sure why it can change ownership, chaning chmod is what we seen in the past, but ownership is strange as it should not know what new one, it probably related with somewhere on your php setting and executable as user you run.

I suggest to not run on docker as it may be the root of the issue.

I will may still merge it to sync with rector.

Not an option in our workflow. Thank you for the test tho !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants