DevStack offers shell scripts to build OpenStack development environments. Getting up and running with DevStack is reasonably easy, however, there are a couple things to know if you are new to it. I’m going to cover the basics on how to get an OpenStack environment up and running using DevStack on a Cloud VM.
Disclosure: As of the date of this article I work for Rackspace. I do not represent Rackspace in any way, I’m simply using Rackspace Cloud as its the most convenient for me.
I’m going to create a performance VM that will utilize SSDs as well as 8vCPUs and 8g GB of RAM. You can choose to test on less a less powerful VM but try to give the OpenStack environment as much RAM as you can. Please keep in mind this is not for a production release, DevStack is a way to get a development/testing environment up in a quick and easy fashion.
First, I’ll pick Ubuntu 12.04:
Second, I’m going to pick a performance VM with an SSD drive and more horsepower than a standard VM:
Let the VM spin up and capture the login details and IP address.
Once the VM is ready log into it and run the following commands:
$ sudo apt-get update $ sudo apt-get install git -y $ git clone https://github.com/openstack-dev/devstack.git $ ./devstack/tools/create-stack-user.sh $ mv devstack/ /opt/stack/ $ chown -R stack:stack /opt/stack/devstack/ $ su - stack $ cd /opt/stack/devstack/ $ nano local.conf
Inside the local.conf add the following and enable any other services you want installed:
[[local|localrc]] # enable the services you want, ie: marconi # enable_service marconi # This makes it easier to use instead of # the longer PKI tokens KEYSTONE_TOKEN_FORMAT=UUID # set passwords to something simple # for dev/testing purposes DATABASE_PASSWORD=password RABBIT_PASSWORD=password SERVICE_TOKEN=password SERVICE_PASSWORD=password ADMIN_PASSWORD=password
The stack.sh will take a while to run and pump out a ton of console information. When its finished it will dump out the passwords for the demo and admin accounts as well as the endpoint for Horizon (which you should log in with to start playing around with the environment, etc.).
You will also notice above that I ran the create-stack-user.sh script to create a user called stack. I then made the stack user the owner of the files in /opt/stack/devstack/.
Once installed you can find the project’s config files in /etc/*.
One final note, you can put the settings we used into the localrc file but the new preferred method is to use local.conf.