How to adjust Apache web server to run Magento 2 in a subdirectory

- Fire development, Magento 2

Magento 2 Development

To adjust Apache web server to run Magento 2 in a subdirectory utilize the following .htaccess files:

  1. .htaccess
  2. pub/.htaccess
  3. pub/media/.htaccess
  4. pub/static/.htaccess

Find the RewriteEngine on line: magento/magento2/blob/2.0.0/.htaccess#L145-L145

Place this code right after the line:

Now, you should replace store with a subdirectory path.

Source

More tips from the Cookbook