Skip to content

Commit 45ce982

Browse files
dklyleianw
authored andcommitted
Moving horizon compression offline
Making the horizon scss compilation and compression happen offline. Potentially fixing an issue with parallel compression in devstack. Related-Bug: #1345955 Change-Id: I066c80e06a92302a3f8dc5fd45d127fbde6cf99c
1 parent 9bfdea8 commit 45ce982

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

lib/horizon

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,8 @@ function init_horizon {
9999
local local_settings=$HORIZON_DIR/openstack_dashboard/local/local_settings.py
100100
cp $HORIZON_SETTINGS $local_settings
101101

102+
_horizon_config_set $local_settings "" COMPRESS_OFFLINE True
103+
102104
_horizon_config_set $local_settings "" OPENSTACK_HOST \"${KEYSTONE_SERVICE_HOST}\"
103105
_horizon_config_set $local_settings "" OPENSTACK_KEYSTONE_URL "\"${KEYSTONE_SERVICE_PROTOCOL}://${KEYSTONE_SERVICE_HOST}:${KEYSTONE_SERVICE_PORT}/v2.0\""
104106
if [[ -n "$KEYSTONE_TOKEN_HASH_ALGORITHM" ]]; then
@@ -140,6 +142,9 @@ function init_horizon {
140142
# and run_process
141143
sudo rm -f /var/log/$APACHE_NAME/horizon_*
142144

145+
DJANGO_SETTINGS_MODULE=openstack_dashboard.settings django-admin.py collectstatic --noinput
146+
DJANGO_SETTINGS_MODULE=openstack_dashboard.settings django-admin.py compress --force
147+
143148
}
144149

145150
# install_django_openstack_auth() - Collect source and prepare

0 commit comments

Comments
 (0)