- Apache web server installed and running (this guide is assuming a ubuntu/debian setup).
- Open
/etc/apache/sites-enabled/000-default.conf
in a text editor. - Locate the section for the desired directory where you want to enable directory listing or set one up like this (Assuming the document root and directory for the listing is at
/srv/data
:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /srv/data
<Directory /srv/data>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
-
Change the Document Root within the configuration file, if needed.
-
You may need to activate the rewrite module with the following command
sudo a2enmod rewrite
-
Restart Apache
systemctl restart apache2
-
You also may want to add some theme, Abba has some really fancy options. Otherwise you can provide an own styling
.htaccess
like this:
- TO-DO: Include custom .htaccess