Home SaltStack-Formulas Project Introduction

Quick Deploy on OpenStack with Heat

Single node deployments are a great way to setup an SaltStack-Formulas cloud for:

  • a service development environment
  • an overview of how all of the OpenStack services and roles play together
  • a simple lab deployment for testing

It is possible to run full size proof-of-concept deployment on OpenStack with Heat template, the stack has following requirements for cluster deployment:

  • At least 200GB disk space
  • 70GB RAM

The single-node deployment has following requirements:

  • At least 80GB disk space
  • 16GB RAM

Available Heat Templates

The app_single environment consists of three nodes.

FQDN Role IP
config.openstack.local Salt master node 10.10.10.200
control.openstack.local OpenStack control node 10.10.10.201
compute.openstack.local OpenStack compute node 10.10.10.202

Heat Client Setup

The preffered way of installing OpenStack clients is isolated Python environment. To creat Python environment and install compatible OpenStack clients, you need to install build tools first.

Installation on Ubuntu

Install required packages:

$ apt-get install python-dev python-pip python-virtualenv build-essential

Now create and activate virtualenv venv-heat so you can install specific versions of OpenStack clients.

$ virtualenv venv-heat
$ source ./venv-heat/bin/activate

Use following requirements.txt. Clients were tested with Juno and Kilo Openstack versions.


python-cinderclient>=1.3.1,<1.4.0
python-glanceclient>=0.19.0,<0.20.0
#python-heatclient>=0.6.0,<0.7.0
git+https://github.com/tcpcloud/python-heatclient.git@stable/juno#egg=heatclient
python-keystoneclient>=1.6.0,<1.7.0
python-neutronclient>=2.2.6,<2.3.0
python-novaclient>=2.19.0,<2.20.0
python-swiftclient>=2.5.0,<2.6.0

oslo.config>=2.2.0,<2.3.0
oslo.i18n>=2.3.0,<2.4.0
oslo.serialization>=1.8.0,<1.9.0
oslo.utils>=1.4.0,<1.5.0

Put requirements into file and install them.

$ pip install -r requirements.txt

If everything goes right, you should be able to use openstack clients, heat, nova, etc.

Connecting to OpenStack Cloud

Setup OpenStack credentials so you can use openstack clients. You can download openrc file from Openstack dashboard and source it or execute following commands with filled credentials:

$ vim ~/openrc

export OS_AUTH_URL=https://<openstack_endpoint>:5000/v2.0
export OS_USERNAME=<username>
export OS_PASSWORD=<password>
export OS_TENANT_NAME=<tenant>

Now source the OpenStack credentials:

$ source openrc

To test your sourced variables:

$ env | grep OS

Some resources required for heat environment deployment.

Get Network Resource Name

The public network is needed for setting up both testing heat stacks. The network ID can be found in Openstack Dashboard or by running following command:

$ neutron net-list

Get Image Resource Name

Image ID is required to run OpenStack Salt lab templates, Ubuntu 14.04 LTS is required as config_image and image for one of the supported platforms is required as instance_image, used for OpenStack instances. To lookup for actual installed images run:

$ glance image-list

Launching the Heat Stack

Download heat templates from this repository.

$ git clone git@github.com:openstack/salt-formulas.git
$ cd doc/source/_static/scripts/

Now you need to customize env files for stacks, see examples in envs directory doc/source/_static/scripts/envs and set required parameters.

Full examples of env files for the two respective stacks: