From fc6479b9c8f2b8fb16765de3bbf8d9b91a7fa24c Mon Sep 17 00:00:00 2001 From: Pranav C Date: Mon, 12 Feb 2024 15:25:12 +0530 Subject: [PATCH] chore: check openssl installed or not Signed-off-by: Pranav C --- docker-compose/setup-script/noco.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/docker-compose/setup-script/noco.sh b/docker-compose/setup-script/noco.sh index 482ec01708..422ea0026d 100644 --- a/docker-compose/setup-script/noco.sh +++ b/docker-compose/setup-script/noco.sh @@ -77,7 +77,7 @@ fi # d. Check if required tools are installed echo " | Checking if required tools (docker, docker-compose, lsof) are installed..." -for tool in docker docker-compose lsof; do +for tool in docker docker-compose lsof openssl; do if ! command_exists "$tool"; then echo "$tool is not installed. Setting up for installation..." if [ "$tool" = "docker-compose" ]; then @@ -198,8 +198,6 @@ fi # *************************** SETUP START ************************************* # Generate a strong random password for PostgreSQL -#STRONG_PASSWORD=$(cat /dev/urandom | tr -dc '[:alnum:]' | head -c 20) -#STRONG_PASSWORD=$(openssl rand -base64 32) STRONG_PASSWORD=$(openssl rand -base64 48 | tr -dc 'a-zA-Z0-9!@#$%^&*()-_+=' | head -c 32) # Encode special characters in the password for JDBC URL usage ENCODED_PASSWORD=$(urlencode "$STRONG_PASSWORD")