aboutsummaryrefslogtreecommitdiffstats
path: root/environments/neutron-l2gw.yaml
blob: bba0968ae708ed6994b51c3a564e6ddae3a7dd6f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# A Heat environment file that can be used to deploy Neutron L2 Gateway service
#
# Currently there are only two service provider for Neutron L2 Gateway
# The default option is a dummy driver that allows to enable the API.
# In order to enable other backend, replace the content of L2gwServiceProvider
#
# - L2 gateway agent: L2GW:l2gw:networking_l2gw.services.l2gateway.service_drivers.rpc_l2gw.L2gwRpcDriver:default
# - OpenDaylight: L2GW:OpenDaylight:networking_odl.l2gateway.driver.OpenDaylightL2gwDriver:default
resource_registry:
  OS::TripleO::Services::NeutronL2gwApi: ../puppet/services/neutron-l2gw-api.yaml
  OS::TripleO::Services::NeutronL2gwAgent: ../puppet/services/neutron-l2gw-agent.yaml

parameter_defaults:
  NeutronServicePlugins: "networking_l2gw.services.l2gateway.plugin.L2GatewayPlugin"
  L2gwServiceProvider: ['L2GW:l2gw:networking_l2gw.services.l2gateway.service_drivers.L2gwDriver:default']

  # Optional
  # L2gwServiceDefaultInterfaceName: "FortyGigE1/0/1"
  # L2gwServiceDefaultDeviceName: "Switch1"
  # L2gwServiceQuotaL2Gateway: 10
  # L2gwServicePeriodicMonitoringInterval: 5
  # L2gwAgentOvsdbHosts: ["ovsdb1:127.0.0.1:6632"]
  # L2gwAgentEnableManager: False
  # L2gwAgentManagerTableListeningPort: "6633"
  # L2gwAgentPeriodicInterval: 20
  # L2gwAgentMaxConnectionRetries: 10
  # L2gwAgentSocketTimeout: 30
n> "rpm=\$(rpm -qa | grep 'kernel-${KERNEL_VERSION}' | awk '{print \$1}'); rpm -ev \$rpm" sudo ssh root@$HOST_IP "rm -rf /boot/initramfs-${KERNEL_VERSION}*.img" sudo ssh root@$HOST_IP "grub2-mkconfig -o /boot/grub2/grub.cfg" sudo ssh root@$HOST_IP "reboot" } #Cleaning up the test environment before running cyclictest through yardstick. env_clean #Creating a docker image with yardstick installed. ( cd ${docker_image_dir}; sudo docker build -t kvmfornfv:latest --no-cache=true . ) if [ ${?} -ne 0 ] ; then echo "Docker image build failed" id=$(sudo docker ps -a | head -2 | tail -1 | awk '{print $1}'); sudo docker rm -f $id exit 1 fi time_stamp=$(date +%Y%m%d%H%M%S) volume=/tmp/kvmtest-${time_stamp} mkdir -p $volume/{image,rpm,scripts} #copying required files to run yardstick cyclic testcase mv $WORKSPACE/build_output/kernel-${KERNEL_VERSION}*.rpm $volume/rpm cp -r $WORKSPACE/ci/envs/* $volume/scripts cp -r $WORKSPACE/tests/cyclictest-node-context.yaml $volume cp -r $WORKSPACE/tests/pod.yaml $volume #Launching ubuntu docker container to run yardstick sudo docker run -i -v $volume:/opt --net=host --name kvmfornfv \ kvmfornfv:latest /bin/bash -c "cd /opt/scripts && ls; ./cyclictest.sh" #Verifying the results of cyclictest result=`grep -o '"errors":[^,]*' $volume/yardstick.out | awk -F '"' '{print $4}'` if [ -z "$result" ]; then echo "####################################################" echo "" echo `grep -o '"data":[^}]*' $volume/yardstick.out | awk -F '{' '{print $2}'` echo "" echo "####################################################" #cleaning the environment after executing the test through yardstick. env_clean #Cleaning the latest kernel changes on host after executing the test. host_clean exit 0 else echo "Testcase failed" echo `grep -o '"errors":[^,]*' ${volume}/yardstick.out | awk -F '"' '{print $4}'` #cleaning the environment after executing the test through yardstick. env_clean #Cleaning the latest kernel changes on host after executing the test. host_clean exit 1 fi