From c57e8e433621d31d7b9bb9c992dd3602ef74490c Mon Sep 17 00:00:00 2001 From: Evgeniy Antonyuk Date: Mon, 18 Mar 2024 18:32:43 +0700 Subject: [PATCH] Fix the UrlShortener service connection to a custom database port --- run-community-server.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/run-community-server.sh b/run-community-server.sh index 213db28..2567d58 100644 --- a/run-community-server.sh +++ b/run-community-server.sh @@ -660,6 +660,7 @@ set +x find "${APP_SERVICES_DIR}/ASC.UrlShortener/config" -type f -name "*.json" -exec sed -i \ -e "s!\(\"host\":\).*,!\1 \"${MYSQL_SERVER_HOST}\",!" \ +-e "/\"sql\": {/,/}/ s!\(\"port\":\).*,!\1 ${MYSQL_SERVER_PORT},!" \ -e "s!\(\"user\":\).*,!\1 \"${MYSQL_SERVER_USER}\",!" \ -e "s!\(\"password\":\).*,!\1 \"${MYSQL_SERVER_PASS//!/\\!}\",!" \ -e "s!\(\"database\":\).*!\1 \"${MYSQL_SERVER_DB_NAME}\"!" {} \;