Openstack-dashboard Development Environment Building and openstack Building

Source: Internet
Author: User

Openstack-dashboard Development Environment Building and openstack Building

1. during the development process, it is generally necessary to run the dashboard component separately in your local linux system (Ubuntu or centos), which is preferred. If you are not used to it, you can use vmwareworkstation to install a virtual machine and switch over at any time.


2. install some required packages for the dashboard, including openstack-dashboard memcached, configure the/etc/openstack-dashboard/local_settings file, modify the OPENSTACK_HOST file, this points to the ip address of the server installed on the keystone server, which is generally a controller.


3. Set up the compiling environment. I chose eclipse + pydev. In fact, pycharm is more convenient to use, but it is only necessary to compile this item first. After changing it, it is difficult to adapt.


4. Create a project under eclipse and copy/usr/share/openstack-dashboard horizon openstack_auth to the project directory,


5. Set the setting. py file, debug = true,


6. manage. py runserver 0.0.0.0: 8000 -- insecure (note, -- insecure is especially important. Otherwise, you will find that static files cannot be loaded ,)




How to build an openstack-dashboard Development Environment

Build a dashboard Development Environment
The following are all normal user identities
On the node that runs the controller (the node of the dashboard), perform the following operations.
The powerful Django provides the Web server architecture function. Test the development environment, instead of modifying the normal dashboard.
As a development test, dashboard provides a script method for building a development environment.
This is actually a simple configuration of web servers. There are two methods to configure multiple different URLs on a node:
One is to use multiple IP addresses based on IP addresses, because linux can set multiple IP addresses for one Nic.
Second, use different ports for different URLs Based on ports. This is the method used in this article.
The main steps are to set up the environment, configure access parameters, and run the service.
A. Preparation
Cd ~
Pwd
/Home/clw
Mkdir github
Cd github
Git clone github.com/openstack/horizon.git
Cd horizon
Git pull
Cd ~
Mkdir src
Cd src
Cp-r ~ /Github/horizon src/
Cd src/horizon
Cp ~ /Src/horizon/openstack_dashboard/local/local_settings.py.example ~ /Src/horizon/openstack_dashboard/local/local_settings.py
B. Build an environment
Cd ~ /Src/horizon
Sudo python tools/install_venv.py
Source. venv/bin/activate
Python manage. py runserver 0.0.0.0: 8080
After running the runserver service, a service is run in the backend of the server.
Enter 192.168.1.125: 8080 in the local browser.
User Name admin
Openstack Login Password
The browser must use a browser that supports html5. We recommend that you use the latest firefox and chrome. IE9 is not compatible.
 
How do you build an OpenStack development environment?

You can download a stackops iso and install it quickly.
Openstack provides RESTful APIs, which can be used in common development environments.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.