Mycket enklare (och bättre så vitt jag vet), att göra det med virtualhosts.
Kopiera in detta till din /etc/apache2.conf:
Kod:
<VirtualHost *:80>
ServerName www.hemsida.se
Redirect permanent / https://hemsida.se/
</VirtualHost>
Sedan får du starta om Apache2 vilket du kan göra på två sätt:
service apache2 restart eller
/etc/init.d/apache2 restart