
This patch aims to support: - ml2 configuration for Open-vSwitch & Linux Bridge plugins - mechanism drivers: flat, gre, vlan vxlan - l2 population support for OVS & linux bridge plugins implement blueprint ml2-support Change-Id: I9a4224f899e95411c509f583bf04dfc4dd0de25b Signed-off-by: Emilien Macchi <emilien.macchi@enovance.com>
31 lines
1.0 KiB
Puppet
31 lines
1.0 KiB
Puppet
#
|
|
# Copyright (C) 2013 eNovance SAS <licensing@enovance.com>
|
|
#
|
|
# Author: Emilien Macchi <emilien.macchi@enovance.com>
|
|
#
|
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may
|
|
# not use this file except in compliance with the License. You may obtain
|
|
# a copy of the License at
|
|
#
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
#
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
# License for the specific language governing permissions and limitations
|
|
# under the License.
|
|
#
|
|
# Advanced testing when using GRE
|
|
#
|
|
|
|
define neutron::plugins::ml2::validate_tunnel_id_ranges {
|
|
$first_id = regsubst($name,'^(\d+):(\d+)$','\1') + 0
|
|
$second_id = regsubst($name,'^(\d+):(\d+)$','\2') + 0
|
|
if (($second_id - $first_id) > 1000000) {
|
|
fail('tunnel id ranges are to large.')
|
|
}
|
|
if (($second_id - $first_id) < 0 ) {
|
|
fail('tunnel id ranges are invalid.')
|
|
}
|
|
}
|