Author: Jonas Pfannschmidt
Email: jonas.pfannschmidt at gmail.com
Date: 19/05/2015
The following is a short description on how to setup OpenStack Horizon in PyCharm. Unfortunately Django, the web-framework used by Horizon, is only supported in PyCharm Professional - The community edition is not sufficient.
A prerequisite is a running OpenStack installation. Horizon needs at least Keystone to communiacte to, although other services are needed as well to do anything useful. My recommendation is to use a devstack installation in a virtual machine. The development Horizon will still run on the local machine but it will point the Keystone within the devstack VM.
By default Horizon logs all messages with INFO level or higher to the console. For development purposes it makes sense to change this to DEBUG. This can be changed in the file openstack_dashboard/local/local_settings.py. In this file, search for LOGGING and change the console handler to DEBUG.
... LOGGING = { 'version': 1, # When set to True this will disable all logging except # for loggers specified in this configuration dictionary. Note that # if nothing is specified here and disable_existing_loggers is True, # django.db.backends will still log unless it is disabled explicitly. 'disable_existing_loggers': False, 'handlers': { 'null': { 'level': 'DEBUG', 'class': 'django.utils.log.NullHandler', }, 'console': { # Set the level to "DEBUG" for verbose output logging. 'level': 'DEBUG', 'class': 'logging.StreamHandler', }, }, ...