Route public interface

This commit is contained in:
vic 2013-02-24 06:19:42 +04:00
parent 032a3ab3d4
commit 4631a01096
2 changed files with 7 additions and 2 deletions

View File

@ -7,7 +7,8 @@ from fuel_test.ci.ci_base import CiBase
from fuel_test.node_roles import NodeRoles from fuel_test.node_roles import NodeRoles
from fuel_test.settings import CONTROLLERS, COMPUTES,\ from fuel_test.settings import CONTROLLERS, COMPUTES,\
STORAGES, PROXIES,\ STORAGES, PROXIES,\
EMPTY_SNAPSHOT, POOLS, INTERFACE_ORDER EMPTY_SNAPSHOT, POOLS, INTERFACE_ORDER, ROUTED_INTERFACE
class CiCobbler(CiBase): class CiCobbler(CiBase):
def node_roles(self): def node_roles(self):
@ -41,7 +42,8 @@ class CiCobbler(CiBase):
pool = self.manager.create_network_pool( pool = self.manager.create_network_pool(
networks=[network], prefix=int(new_prefix)) networks=[network], prefix=int(new_prefix))
networks.append(self.manager.network_create( networks.append(self.manager.network_create(
name=name, environment=environment, pool=pool)) name=name, environment=environment, pool=pool,
forward='route' if name==ROUTED_INTERFACE else 'nat'))
for name in self.node_roles().master_names + self.node_roles().cobbler_names + self.node_roles().stomp_names: for name in self.node_roles().master_names + self.node_roles().cobbler_names + self.node_roles().stomp_names:
self.describe_node(name, networks) self.describe_node(name, networks)
for name in self.node_roles().compute_names: for name in self.node_roles().compute_names:

View File

@ -67,6 +67,7 @@ EMPTY_SNAPSHOT = os.environ.get('EMPTY_SNAPSHOT', 'empty')
OPENSTACK_SNAPSHOT = os.environ.get('OPENSTACK_SNAPSHOT', 'openstack') OPENSTACK_SNAPSHOT = os.environ.get('OPENSTACK_SNAPSHOT', 'openstack')
INTERFACE_ORDER = ('public', 'internal', 'private') INTERFACE_ORDER = ('public', 'internal', 'private')
ROUTED_INTERFACE = 'public'
INTERFACES = { INTERFACES = {
'public': 'eth0', 'public': 'eth0',
@ -95,3 +96,5 @@ POOLS = {
'internal': os.environ.get('INTERNAL_POOL', 'internal': os.environ.get('INTERNAL_POOL',
DEFAULT_POOLS.get(OS_FAMILY).get('internal')).split(':') DEFAULT_POOLS.get(OS_FAMILY).get('internal')).split(':')
} }