From 4c86914e76cff2dba7710e4847d99cdb0ad21e48 Mon Sep 17 00:00:00 2001 From: Michael James Hoppal Date: Thu, 12 Feb 2015 09:43:31 -0700 Subject: [PATCH] Modify README to include steps to set up dev environment Change-Id: I093bcd2de76a4e7154e4ab1245ad0a4e09b0f60d --- README.md | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 55 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index ecd2c438..94ad3308 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,10 @@ monasca-ui ========== Monasca UI is implemented as a horizon plugin that adds panels to horizon. It is installed into devstack -by monasca-vagrant. For a UI development setup: +by monasca-vagrant. + +#Deployment Set Up + * git clone https://github.com/openstack/horizon.git # clone horizon * git clone https://github.com/hpcloud-mon/grafana.git * ln -s grafana/src horizon/static/grafana @@ -12,8 +15,57 @@ by monasca-vagrant. For a UI development setup: * Edit openstack_dashboard/settings.py to include the following two lines: * import monitoring.enabled * monitoring.enabled, #Add to the settings.update_dashboards list -# -License + + +#Development Environment Set Up + +##Get the Code + +``` +git clone https://github.com/stackforge/monasca-ui.git # clone monasca-ui +git clone https://github.com/openstack/horizon.git # clone horizon +git clone https://github.com/hpcloud-mon/grafana.git # clone grafana +``` + +##Set up Horizon + +Since Monasca UI is a horizon plugin the first step is to get their development environment set up. + +``` +cd horizon +./run_tests.sh +cp openstack_dashboard/local/local_settings.py.example openstack_dashboard/local/local_settings.py +``` + +Pro Tip: Make sure you have horizon running correctly before proceeding. +For more details go to http://docs.openstack.org/developer/horizon/quickstart.html#setup + +##Set up Monasca-UI + +* Edit openstack_dashboard/local/local_settings.py to modify the OPENSTACK_HOST IP address to point to devstack. +* Add monasca-client to requirements.txt. Get the latest version from https://pypi.python.org/pypi/python-monascaclient +* Link monasca into Horizon: + +``` +cp ../monasca-ui/monitoring/enabled/_50_admin_add_monitoring_panel.py openstack_dashboard/enabled/. +ln -s ../monasca-ui/monitoring monitoring +./run_tests #load monasca-client into virtualenv +``` + +##Set up Grafana + +``` +cd static +ln -s ../../grafana/src grafana +``` + +##Start Server + +``` +./run_tests.sh --runserver +``` + +#License Copyright (c) 2014 Hewlett-Packard Development Company, L.P.