How to configure horizon for HTTPS and SSL in the latest DevStack release?

asked 2017-06-07 19:16:29 -0500

zetret12 gravatar image

Hi, Here is the horizon.conf file;

< VirtualHost *:80 > #added space because this website doesn't seem to allow the tags

WSGIScriptAlias /dashboard /opt/stack/horizon/openstack_dashboard/wsgi/django.wsgi

WSGIDaemonProcess horizon user=stack group=stack processes=3 threads=10 home=/opt/stack/horizon display-name=%{GROUP}

WSGIApplicationGroup %{GLOBAL}

SetEnv APACHE_RUN_USER stack
SetEnv APACHE_RUN_GROUP stack
WSGIProcessGroup horizon

DocumentRoot /opt/stack/horizon/.blackhole/
Alias /dashboard/media /opt/stack/horizon/openstack_dashboard/static
Alias /dashboard/static /opt/stack/horizon/static

RedirectMatch "^/$" "/dashboard/"

<Directory />
    Options FollowSymLinks
    AllowOverride None
</Directory>

<Directory /opt/stack/horizon/>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    # Apache 2.4 uses mod_authz_host for access control now (instead of
    #  "Allow")
    <IfVersion < 2.4>
        Order allow,deny
        Allow from all
    </IfVersion>
    <IfVersion >= 2.4>
        Require all granted
    </IfVersion>
</Directory>
<IfVersion >= 2.4>
  ErrorLogFormat "%{cu}t %M"
</IfVersion>
ErrorLog /var/log/apache2/horizon_error.log
LogLevel warn
CustomLog /var/log/apache2/horizon_access.log combined

</virtualhost>

WSGISocketPrefix /var/run/apache2

I have generated certificates for SSL and HTTPS seems to be working.

However, I DON'T UNDERSTAND how to set the Document root for the Horizon dashboard and there seems to be no documentation on it. I copy-pasted the same from above (port 80) to my default-ssl.conf file, and enabled it - but it doesn't work. Can someone explain what to set as the document root for HTTPS?

edit retag flag offensive close merge delete