<VirtualHost *:80>
	ServerAdmin contact@localhost
	ServerName jsbeta.stream-up.local
	ServerAlias jsbeta.stream-up.localhost
	DocumentRoot /var/www/html/js/

	<Directory /var/www/html/js/>
        Options Indexes FollowSymLinks
        AllowOverride All
        Require all granted
    </Directory>

    <IfModule mod_rewrite.c>
        RewriteEngine on
        RewriteCond %{SERVER_PORT} 80
        RewriteRule ^(.*)$ https://%{HTTP_HOST}$1 [R,QSA]
    </IfModule>

    php_value upload_max_filesize "500M"
    php_value post_max_size "500M"
    php_value max_input_time "259200"
    php_value max_input_time "259200"

    php_value default_charset ISO-8859-1
    AddDefaultCharset ISO-8859-1

    Header Set Access-Control-Allow-Origin "*"

	ErrorLog ${APACHE_LOG_DIR}/js-error.log
	CustomLog ${APACHE_LOG_DIR}/js-access.log combined
</VirtualHost>

<VirtualHost *:443>
    SSLEngine on
    SSLCertificateFile "/etc/ssl/stream-up.local.crt"
    SSLCertificateKeyFile "/etc/ssl/stream-up.local.key"

	ServerAdmin contact@localhost
	ServerName jsbeta.stream-up.local
	DocumentRoot /var/www/html/js/

	<Directory /var/www/html/js/>
        Options Indexes FollowSymLinks
        AllowOverride All
        Require all granted
    </Directory>

    php_value upload_max_filesize "500M"
    php_value post_max_size "500M"
    php_value max_input_time "259200"
    php_value max_input_time "259200"

    php_value default_charset ISO-8859-1
    AddDefaultCharset ISO-8859-1

    Header Set Access-Control-Allow-Origin "*"

	ErrorLog ${APACHE_LOG_DIR}/js-error.log
	CustomLog ${APACHE_LOG_DIR}/js-access.log combined
</VirtualHost>