<VirtualHost *:80>
    ServerName dummy
    DocumentRoot /var/www/html/storytelling/
    CustomLog /var/log/apache2/access_dummy.log combined
    ErrorLog /var/log/apache2/error_sfogliaqui.net.log

    Alias /img /var/www/html/smssmart/img

    <Directory /var/www/html/storytelling>
        Options -Indexes +FollowSymLinks +MultiViews
        AllowOverride All
        Require all granted
    </Directory>
    Header set Access-Control-Allow-Origin "*"
    # RewriteCond %{HTTP:X-Forwarded-Proto} ^$
    # RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
</VirtualHost>

<IfModule mod_ssl.c>
    <VirtualHost *:443>
        DocumentRoot /var/www/html/storytelling
        ServerName dummy
        CustomLog /var/log/apache2/access_sfogliaqui.net.log combined
        ErrorLog /var/log/apache2/error_sfogliaqui.net.log

        Alias /img /var/www/html/smssmart/img

        <Directory /var/www/html/storytelling>
            Options -Indexes +FollowSymLinks +MultiViews
            AllowOverride All
            Require all granted
        </Directory>
        Header set Access-Control-Allow-Origin "*"
        Include /etc/letsencrypt/options-ssl-apache.conf
        SSLCertificateFile /etc/letsencrypt/live/dummy/fullchain.pem
        SSLCertificateKeyFile /etc/letsencrypt/live/dummy/privkey.pem
    </VirtualHost>
</IfModule>