Hi there!
I am quite new in using October CMS or CMS at all.
The setup went quite smooth but now I have an issue regarding the media manager.
I can access all files, that I add to the media manager’s top collection folder without issues.
I can also create new sub-folders and upload my files into them.
Looking at the files in the file manager of the sever backend, I can see that by default the sub-folders and files within them don’t have read permission for public activated.
I can manually change the permission of files and folders from the server backend, but that of course is not how it is supposed to work. And it is quite tiring to do that for all future files…
Can anyone help me resolve this issue? I don’t know if I need to change sth. with the server settings or in october cms or both… As I said I am a beginner.
I have been looking for a solution but couldn’t seem to find it or anyone with a simmilar issue.
I am currently running Version 3.0.40 of October CMS.
This looks like it could be related to the default permission mask set by your server. You can configure October CMS to use more relaxed permissions by opening the .env configuration file and changing these settings:
DEFAULT_FILE_MASK=775
DEFAULT_FOLDER_MASK=775
By default, these are set to 755 and using 775 or 777 should help, however, you should check with your hosting provider if this is safe to do.
I’d like to add on this. With Plesk (It looks like Plesk) You might want to set the DEFAULT_FOLDER_MASK to 644. That’s the default I believe. I could be wrong tho
Thank you very much for the quick answers! ^^
I tried changing the configuration file to the suggestions and create new folders each time and files to test it on.
I tried:
DEFAULT_FILE_MASK=775
DEFAULT_FOLDER_MASK=775
DEFAULT_FILE_MASK=777
DEFAULT_FOLDER_MASK=777
And in combination with the above I also tried:
DEFAULT_FOLDER_MASK=644
Sadly, it is still showing the same error.
Do I need to do anything specific after changing the file, that I haven’t done?
The files itself appear to be fine. It is just the folders that dont have reading permission.
Maybe it is worth mentioning, that I had a version of October 2.x running on the exact same hosting server before, which worked just fine.
But I decided to reinstall october from scratch with the latest version and afterwards this issue appeared.
Had a quick look at this today, it looks like it may be something introduced with Laravel 9 used in October 3. The permission masks discussed here are not applying to the “Flysystem” implementation.
@Pandaboy, a patch was made today, try updating to the latest version (>v3.0.42) to see if it helps.