cancel
Showing results for 
Search instead for 
Did you mean: 

hi guy,i have a question,please help me!

hi guy,i have a question,please help me!

 

I've tried 3 times now to install Magento 2 each time facing issues with permissions.

On initial upload I get 500 server errors because the permissions don't allow access to the files.

I can work around this by setting the following permissions in SSH:

 

find . -type f -exec chmod 644 {} \;
find . -type d -exec chmod 755 {} \;
find ./var -type d -exec chmod 777 {} \;
find ./pub/media -type d -exec chmod 777 {} \;
find ./pub/static -type d -exec chmod 777 {} \;
chmod 777 app/etc
chmod 644 app/etc/*.xml

This gives me enough access to install the site.

After which there's further issues in that the style sheets and JavaScript create the same 500 error from the beginning.

Again playing around with the permissions can fix this, with a little more difficulty.

 

But even then any new file introduced (product image for example) will have the wrong permissions and cause the 500 error.

 

--

 

There must be a way to do this "properly" can anyone help.

 

1 REPLY 1

Re: hi guy,i have a question,please help me!

Hello,

 

Make sure you SSH user under same group apache2 group.

 

 


Problem solved? Click Kudos & Accept as Solution!
Sunil Patel
Magento 2 Certified Professional Developer & Frontend Developer