Developing OpenStack networking applications
We briefly discussed the OpenStack Networking service (Neutron) in Chapter 2, Exploring AWS Cloud. This service allows the creation and manipulation of virtual networks within the OpenStack environment. When a virtual machine instance is launched, it uses the networks governed by the networking service.
By default, an OpenStack installation provides two networks: public and private. However, your cloud application may require you to create several different networks for different virtual machine instances belonging to different groups. Let's see how we can manipulate networking functionalities using the Python SDK.
Networks
We will look at how we can create and configure OpenStack networking components programmatically.
Creating a network/subnet
A new virtual network can be created by invoking the create_network()
function call and specifying the name of the network. Once a network is created, we must create a subnet that defines the IP version (IPv4...