diff options
author | Yang Xu <yang.xu@futurewei.com> | 2019-06-26 01:50:15 -0400 |
---|---|---|
committer | Yang Xu <yang.xu@futurewei.com> | 2019-06-26 12:46:31 +0000 |
commit | 1b31a1d43b9be2938fde5639ab7aaea6262adc4f (patch) | |
tree | 9a4ac9b08801746e311a00c7673ac73c66036b9f /test/vcpe/vcpe.py | |
parent | fdae148d303b3153e2dec38d830d3784491b6f65 (diff) |
Clean up vCPE script
Signed-off-by: Yang Xu <yang.xu@futurewei.com>
Issue-ID: INT-847
Change-Id: I1158442cd73c6e0d943e9cc111cb12dae1381d36
Diffstat (limited to 'test/vcpe/vcpe.py')
-rwxr-xr-x | test/vcpe/vcpe.py | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/test/vcpe/vcpe.py b/test/vcpe/vcpe.py index 375a04e12..3221d482a 100755 --- a/test/vcpe/vcpe.py +++ b/test/vcpe/vcpe.py @@ -1,6 +1,9 @@ #! /usr/bin/python -import sys + import logging +logging.basicConfig(level=logging.INFO, format='%(asctime)s %(levelname)s %(name)s.%(funcName)s(): %(message)s') + +import sys from vcpecommon import * import sdcutils import soutils @@ -57,7 +60,6 @@ def create_one_service(vcpecommon, csar_file, vnf_template_file, preload_dict, s def deploy_brg_only(): - logging.basicConfig(level=logging.INFO, format='%(message)s') logger = logging.getLogger(__name__) vcpecommon = VcpeCommon() @@ -153,9 +155,6 @@ def deploy_custom_service(): def closed_loop(lossrate=0): - if lossrate > 0: - while 'y' != raw_input('Please enter docker container "drools" in Policy VM and type "policy stop". Then enter y here: ').lower(): - continue nodes = ['brg', 'mux'] logger = logging.getLogger('__name__') vcpecommon = VcpeCommon(nodes) @@ -172,7 +171,7 @@ def closed_loop(lossrate=0): time.sleep(2) vcpecommon.set_vgmux_packet_loss_rate(lossrate, vcpecommon.load_vgmux_vnf_name()) if lossrate > 0: - print('Please enter docker container "drools" in Policy VM and type "policy start". Then observe vGMUX being restarted.') + print('Now please observe vGMUX being restarted') def init_so_sdnc(): @@ -216,8 +215,6 @@ def test(): if __name__ == '__main__': - logging.basicConfig(level=logging.DEBUG, format='%(message)s') - print('----------------------------------------------------------------------------------------------------') print(' vcpe.py: Brief info about this program') # print(' vcpe.py sdc: Onboard VNFs, design and distribute vCPE services (under development)') |