Simple:

sudo a2enmode rewrite