Openstack¶
The OpenStack provider allows you to use Enos on an OpenStack cloud. In other words this lets you run OpenStack on OpenStack. In the following, the under-cloud is the underlying OpenStack infrastructure, the over-cloud is the OpenStack configured by Enos.
The over-cloud configured by Enos needs a set of resources to be present on the under-cloud. The first step in the deployment workflow consists in checking or creating such resources. Some resources are mandatory and must be present before the deployment (base image, keypairs, …), some others can be created or reused during the deployment (private networks). For the latter, you can use the default values set by the provider.
For specific under-clouds (e.g Chameleon), specific providers deriving from the OpenStack provider may be used. They will enforce more default values that fit the under-cloud specificities (e.g specific DNS, base image, …)
Installation¶
In addition refer to Getting Started, extra dependencies are required. You can install them with
pip install enos[openstack]
Basic Configuration¶
The provider relies on flavor names to group the wanted resources. The folliwing gives an idea of the resource description available.
provider:
type: openstack
<options see below>
resources:
m1.medium:
control: 1
network: 1
m1.small:
compute: 10
Default provider configuration¶
The OpenStack provider is shipped with the following default options. These options will be set automatically and thus may be omitted in the configuration file.
DEFAULT_CONFIG = {
"type": "openstack",
# True if Enos needs to create a dedicated network to work with
# False means you already have a network, subnet and router to
# your ext_net configured
"configure_network": True,
# Name of the network to use or to create
# It will be use as external network for the upper-cloud
"network": {'name': 'enos-network'},
# Name of the subnet to use or to create
"subnet": {'name': 'enos-subnet', 'cidr': '10.87.23.0/24'},
# DNS server to use when creating the network
"dns_nameservers": ['8.8.8.8', '8.8.4.4'],
# Floating ips pool
"allocation_pool": {'start': '10.87.23.10', 'end': '10.87.23.100'},
# Whether one machine must act as gateway
# - False means that you can connect directly to all the machines
# started by Enos
# - True means that one machine will be assigned a floating ip and used
# as gateway to the others
"gateway": True,
# MANDATORY OPTIONS
'key_name': None,
'image': None,
'user': None
}
These options can be overriden in the provider config.
Deployment¶
Enos will interact with the remote OpenStack APIs. In order to get authenticated you must source your rc file. To use Enos on Openstack there are two distinct cases :
You have direct access to all your machines. You can set
gateway: False
Hint
In this case, prior to the Enos deployment, you have probably started a machine to act as a frontend. This machine is in the same network as those used by Enos
You don’t have direct access to all your machines. You have to set
gateway: True
in the configuration. EnOS will use a freshly started server as a gateway to access the other nodes.
Chameleon Cloud (KVM)¶
This provider is an OpenStack based provider where some options are set to fit the folllowing platform :
Basic Configuration¶
As more default values can be enforced automatically, the following is a valid resources description.
1enable_monitoring: false
2inventory: inventories/inventory.sample
3kolla:
4 enable_heat: false
5 kolla_base_distro: centos
6 kolla_install_type: source
7provider:
8 gateway: true
9 key_name: enos_matt
10 type: chameleonkvm
11registry:
12 type: internal
13resources:
14 m1.medium:
15 compute: 1
16 control: 1
17 network: 1
Default provider configuration¶
The following options will be set automatically and thus may be omitted in the configuration file :
DEFAULT_CONFIG = {
# Name of the provider
'type': 'chameleonkvm',
# Glance image to use
'image': 'CC-Ubuntu16.04',
# User to use to connect to the machines
# (sudo will be used to configure them)
'user': 'cc',
# DNS server to use when creating network
'dns_nameservers': ['129.114.97.1', '129.114.97.2', '129.116.84.203'],
}
These options can be overriden in the provider config.
Chameleon Cloud (Bare Metal)¶
This provider is an OpenStack based provider where some options are set to fit the following platforms :
The provider interacts with blazar to claim automatically a lease.
Basic Configuration¶
1enable_monitoring: false
2inventory: inventories/inventory.sample
3kolla:
4 enable_heat: false
5 kolla_base_distro: centos
6 kolla_install_type: source
7provider:
8 gateway: true
9 key_name: enos_matt
10 type: chameleonbaremetal
11registry:
12 type: internal
13resources:
14 compute_haswell:
15 compute: 1
16 control: 1
17 network: 1
Note that on Chameleon, they are two groups of machines : compute and storage.
Default provider configuration¶
The following options will be set automatically and thus may be omitted in the configuration file.
DEFAULT_CONFIG = {
# Name of the provider
'type': 'chameleonbaremetal',
# Name os the lease to use
'lease_name': 'enos-lease',
# Glance image to use
'image': 'CC-Ubuntu16.04',
# User to use to connect to the machines
# (sudo will be used to configure them)
'user': 'cc',
# True iff Enos must configure a network stack for you
'configure_network': False,
# Name of the network to use or to create
'network': {'name': 'sharednet1'},
# Name of the subnet to use or to create
'subnet': {'name': 'sharednet1-subnet'},
# DNS server to use when creating network
'dns_nameservers': ['130.202.101.6', '130.202.101.37'],
# Experiment duration
'walltime': '02:00:00',
}
These options can be overriden in the provider config.
Warning
A shared-network is used and may limit the features of the over-cloud (e.g floating ips)