Based on the following patch: From: Yoshihiro Kaneko <ykaneko0929@gmail.com> Subject: app: Add quantum adapter Thanks to Kaneko for finding and fixing my bugs. Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com> Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
48 lines
1.9 KiB
Python
48 lines
1.9 KiB
Python
# Copyright (C) 2011 Nippon Telegraph and Telephone Corporation.
|
|
# Copyright (C) 2011 Isaku Yamahata <yamahata at valinux co jp>
|
|
#
|
|
# 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.
|
|
"""
|
|
global flags
|
|
"""
|
|
|
|
import gflags
|
|
|
|
FLAGS = gflags.FLAGS
|
|
|
|
# GLOBAL flags
|
|
gflags.DEFINE_boolean('monkey_patch', False, 'do monkey patch')
|
|
|
|
# app/quantum_adapter
|
|
gflags.DEFINE_string('quantum_url', 'http://localhost:9696',
|
|
'URL for connecting to quantum')
|
|
gflags.DEFINE_integer('quantum_url_timeout', 30,
|
|
'timeout value for connecting to quantum in seconds')
|
|
gflags.DEFINE_string('quantum_admin_username', 'quantum',
|
|
'username for connecting to quantum in admin context')
|
|
gflags.DEFINE_string('quantum_admin_password', 'service_password',
|
|
'password for connecting to quantum in admin context')
|
|
gflags.DEFINE_string('quantum_admin_tenant_name', 'service',
|
|
'tenant name for connecting to quantum in admin context')
|
|
gflags.DEFINE_string('quantum_admin_auth_url', 'http://localhost:5000/v2.0',
|
|
'auth url for connecting to quantum in admin context')
|
|
gflags.DEFINE_string(
|
|
'quantum_auth_strategy',
|
|
'keystone',
|
|
'auth strategy for connecting to quantum in admin context')
|
|
|
|
gflags.DEFINE_string('quantum_controller_addr', None,
|
|
'openflow mehod:address:port to set controller of'
|
|
'ovs bridge')
|