From 57b42d9f179a66f8278417333882246416761121 Mon Sep 17 00:00:00 2001 From: Victor Seva Date: Thu, 10 Feb 2022 15:22:59 +0100 Subject: [PATCH] TT#81700 set_config.sh: fix error when ngcpcfg fails > Thu Feb 10 13:33:16 CET 2022 - Config files > Thu Feb 10 13:33:16 CET 2022 - Added stir file keys > 2022-02-10 13:33:16 spce: Error: Failed to call action 'apply' on 'spce' (see logs on 'spce') > Thu Feb 10 13:33:17 CET 2022 - ngcpcfg apply returned 0 > Thu Feb 10 13:33:17 CET 2022 - Removed apicert.pem > Thu Feb 10 13:33:17 CET 2022 - Setting config debug off > ./set_config.sh: line 125: ./bin/config_debug.pl: No such file or directory > ngcp-type: profile CE Change-Id: Ifbe32da1539d2ce340687b8a0c5ceb7ad1a59ca6 --- set_config.sh | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/set_config.sh b/set_config.sh index ee94c899..83eb14d8 100755 --- a/set_config.sh +++ b/set_config.sh @@ -156,12 +156,14 @@ config() { fi echo "$(date) - Config files" "${BIN_DIR}/config_files.sh" "${GROUP}" - cd /etc/ngcp-config || exit 3 - if ! ngcpcfg --summary-only apply "config debug on via kamailio-config-tests" ; then - echo "$(date) - ngcpcfg apply returned $?" - clean - error_flag=4 - fi + ( + cd /etc/ngcp-config || exit 3 + if ! ngcpcfg --summary-only apply "config debug on via kamailio-config-tests" ; then + echo "$(date) - ngcpcfg apply returned $?" + clean + exit 4 + fi + ) dummy_add || error_flag=5 dummy_up 0|| error_flag=5 dummy_up 1|| error_flag=5