1

I was recently trying to upgrade my Magento 2.2.7 to Magento 2.3.0 and the following message came up in component dependencies

Found non-writable path(s):
/var/www/vhosts/powermyself.com/httpdocs/pub/.htaccess

Upon closer inspection it would seem that the .htaccess file is missing in this folder (although there is still one in pub/static).

Is there any way to get this file back?

6
  • Copy it from github.com/magento/magento2/blob/2.3-develop/pub/.htaccess Commented Feb 13, 2019 at 11:00
  • Thanks. Will I need branch 2.3-develop or 2.2? Commented Feb 13, 2019 at 11:01
  • it depends on your version if it's 2.3 then copy from 2.3 Commented Feb 13, 2019 at 11:08
  • My version is 2.2.7, so should I copy from 2.2? Commented Feb 13, 2019 at 11:11
  • Yes, copy it from 2.2 . Commented Feb 13, 2019 at 11:20

1 Answer 1

2

You can copy .htaccess file from github repository.

Copy it from https://github.com/magento/magento2/blob/2.3-develop/pub/.htaccess

If you have already upgraded to version 2.3, you will need .htaccess file of new version i.e 2.3 otherwise download from 2.2.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.