ocata - theme customization with templates

asked 2017-06-13 09:30:27 -0600

sigsupdev gravatar image


I'm building Openstack Ocata Environment using RDO on CentOS 7 and I am trying to create custom theme with templates. I have created my theme folder in /usr/share/openstack-dashboard/openstack-dashboard/themes and I have registered it in local_settings.py


While restarting httpd service, on command: python /usr/share/openstack-dashboard/manage.py compress; there is a problem:

Traceback (most recent call last):   File "/usr/share/openstack-dashboard/manage.py", line 23, in <module>
    execute_from_command_line(sys.argv)   File "/usr/lib/python2.7/site-packages/django/core/management/__init__.py", line 354, in execute_from_command_line
    utility.execute()   File "/usr/lib/python2.7/site-packages/django/core/management/__init__.py", line 303, in execute
    settings.INSTALLED_APPS   File "/usr/lib/python2.7/site-packages/django/conf/__init__.py", line 48, in __getattr__
    self._setup(name)   File "/usr/lib/python2.7/site-packages/django/conf/__init__.py", line 44, in _setup
    self._wrapped = Settings(settings_module)   File "/usr/lib/python2.7/site-packages/django/conf/__init__.py", line 92, in __init__
    mod = importlib.import_module(self.SETTINGS_MODULE) File "/usr/lib64/python2.7/importlib/__init__.py", line 37, in import_module
    __import__(name)   File "/usr/share/openstack-dashboard/openstack_dashboard/settings.py", line 429, in <module>
    THEME_COLLECTION_DIR, ROOT_PATH)   File "/usr/share/openstack-dashboard/openstack_dashboard/utils/settings.py", line 331, in find_static_files
    (templates_part, override_path) = theme_file.split('/templates/')

My workaround is change in file /usr/share/openstack-dashboard/openstack_dashboard/utils/settings.py line (templates_part, override_path) = theme_file.split('/templates/') to

(templates_part, override_path) = theme_file.split('templates/')

and then everything works, but I am sure that there is a better way (maybe some variable?) to solve it.

Thanks for help,


edit retag flag offensive close merge delete


sigsupdev - is this issue still occurring for you? given that it's been 6mo since you posted this question and no one's responded, I'm tempted to close it out. if you've found a solution, it'd be great if you could post it so it's answered for others who run into the same issue!

mary_grace gravatar imagemary_grace ( 2017-12-14 17:53:52 -0600 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2018-01-19 02:50:12 -0600

zioproto gravatar image

updated 2018-01-20 08:26:42 -0600

Hello, I have the same issue in Pike. I opened a bug and I found the commit that introduced the problem. please follow the bug on https://bugs.launchpad.net/horizon/+b... You workaround makes collectstatic not fail, but it does not work.

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2017-06-13 09:30:27 -0600

Seen: 485 times

Last updated: Jan 20 '18