Project Michael Dings Impressum Login

Howto-Configure-Apache-on-Ubuntu

I am a Howto for the Configuration of Apache.

Installation

Enable Root ssh

Package

$ sudo apt install php libapache2-mod-php
$ sudo apt-get install php-curl
$ sudo systemctl restart apache2

Permissions

# sudo chgrp -R www-data /var/www/html
# sudo find /var/www/html -type d -exec chmod g+rwx {} +
# sudo find /var/www/html -type f -exec chmod g+rw {} +

Config

General

;extension=bz2
extension=curl
;extension=ffi

Virtual Host

<VirtualHost *:80>
        ServerAdmin webmaster@localhost
        DocumentRoot /var/www/html/All-Dings
        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined
        <Directory /var/www/html/All-Dings>
            Options Indexes FollowSymLinks
            AllowOverride All
            Require all granted
        </Directory>
</VirtualHost>
$ sudo a2dissite old-config.conf
$ sudo a2ensite 000-default.conf
$ sudo systemctl restart apache2

Logs

Data

Enable .htaccess

$ sudo a2enmod rewrite && sudo service apache2 restart

Domain-Transfer to AWS

AWS User-Defined-Domains

General Links