diff --git a/Dockerfiles/agent/alpine/docker-entrypoint.sh b/Dockerfiles/agent/alpine/docker-entrypoint.sh index 5b0fb367a..4b269d9eb 100755 --- a/Dockerfiles/agent/alpine/docker-entrypoint.sh +++ b/Dockerfiles/agent/alpine/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent/centos/docker-entrypoint.sh b/Dockerfiles/agent/centos/docker-entrypoint.sh index 5b0fb367a..4b269d9eb 100755 --- a/Dockerfiles/agent/centos/docker-entrypoint.sh +++ b/Dockerfiles/agent/centos/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent/ol/docker-entrypoint.sh b/Dockerfiles/agent/ol/docker-entrypoint.sh index 5b0fb367a..4b269d9eb 100755 --- a/Dockerfiles/agent/ol/docker-entrypoint.sh +++ b/Dockerfiles/agent/ol/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent/rhel/docker-entrypoint.sh b/Dockerfiles/agent/rhel/docker-entrypoint.sh index 5b0fb367a..4b269d9eb 100755 --- a/Dockerfiles/agent/rhel/docker-entrypoint.sh +++ b/Dockerfiles/agent/rhel/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent/ubuntu/docker-entrypoint.sh b/Dockerfiles/agent/ubuntu/docker-entrypoint.sh index 5b0fb367a..4b269d9eb 100755 --- a/Dockerfiles/agent/ubuntu/docker-entrypoint.sh +++ b/Dockerfiles/agent/ubuntu/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent2/alpine/docker-entrypoint.sh b/Dockerfiles/agent2/alpine/docker-entrypoint.sh index cb349d433..958acbcc0 100755 --- a/Dockerfiles/agent2/alpine/docker-entrypoint.sh +++ b/Dockerfiles/agent2/alpine/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent2/centos/docker-entrypoint.sh b/Dockerfiles/agent2/centos/docker-entrypoint.sh index cb349d433..958acbcc0 100755 --- a/Dockerfiles/agent2/centos/docker-entrypoint.sh +++ b/Dockerfiles/agent2/centos/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent2/ol/docker-entrypoint.sh b/Dockerfiles/agent2/ol/docker-entrypoint.sh index cb349d433..958acbcc0 100755 --- a/Dockerfiles/agent2/ol/docker-entrypoint.sh +++ b/Dockerfiles/agent2/ol/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent2/rhel/docker-entrypoint.sh b/Dockerfiles/agent2/rhel/docker-entrypoint.sh index cb349d433..958acbcc0 100755 --- a/Dockerfiles/agent2/rhel/docker-entrypoint.sh +++ b/Dockerfiles/agent2/rhel/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh b/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh index cb349d433..958acbcc0 100755 --- a/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh +++ b/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh @@ -82,7 +82,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-mysql/alpine/docker-entrypoint.sh b/Dockerfiles/proxy-mysql/alpine/docker-entrypoint.sh index 0f05e2871..8b8009f70 100755 --- a/Dockerfiles/proxy-mysql/alpine/docker-entrypoint.sh +++ b/Dockerfiles/proxy-mysql/alpine/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-mysql/centos/docker-entrypoint.sh b/Dockerfiles/proxy-mysql/centos/docker-entrypoint.sh index a1eb92156..cb1f2dea8 100755 --- a/Dockerfiles/proxy-mysql/centos/docker-entrypoint.sh +++ b/Dockerfiles/proxy-mysql/centos/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-mysql/ol/docker-entrypoint.sh b/Dockerfiles/proxy-mysql/ol/docker-entrypoint.sh index a1eb92156..cb1f2dea8 100755 --- a/Dockerfiles/proxy-mysql/ol/docker-entrypoint.sh +++ b/Dockerfiles/proxy-mysql/ol/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-mysql/rhel/docker-entrypoint.sh b/Dockerfiles/proxy-mysql/rhel/docker-entrypoint.sh index a1eb92156..cb1f2dea8 100755 --- a/Dockerfiles/proxy-mysql/rhel/docker-entrypoint.sh +++ b/Dockerfiles/proxy-mysql/rhel/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-mysql/ubuntu/docker-entrypoint.sh b/Dockerfiles/proxy-mysql/ubuntu/docker-entrypoint.sh index a1eb92156..cb1f2dea8 100755 --- a/Dockerfiles/proxy-mysql/ubuntu/docker-entrypoint.sh +++ b/Dockerfiles/proxy-mysql/ubuntu/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-sqlite3/alpine/docker-entrypoint.sh b/Dockerfiles/proxy-sqlite3/alpine/docker-entrypoint.sh index 2ea598d54..aa130bd52 100755 --- a/Dockerfiles/proxy-sqlite3/alpine/docker-entrypoint.sh +++ b/Dockerfiles/proxy-sqlite3/alpine/docker-entrypoint.sh @@ -76,7 +76,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-sqlite3/centos/docker-entrypoint.sh b/Dockerfiles/proxy-sqlite3/centos/docker-entrypoint.sh index 2ea598d54..aa130bd52 100755 --- a/Dockerfiles/proxy-sqlite3/centos/docker-entrypoint.sh +++ b/Dockerfiles/proxy-sqlite3/centos/docker-entrypoint.sh @@ -76,7 +76,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-sqlite3/ol/docker-entrypoint.sh b/Dockerfiles/proxy-sqlite3/ol/docker-entrypoint.sh index 2ea598d54..aa130bd52 100755 --- a/Dockerfiles/proxy-sqlite3/ol/docker-entrypoint.sh +++ b/Dockerfiles/proxy-sqlite3/ol/docker-entrypoint.sh @@ -76,7 +76,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-sqlite3/rhel/docker-entrypoint.sh b/Dockerfiles/proxy-sqlite3/rhel/docker-entrypoint.sh index 2ea598d54..aa130bd52 100755 --- a/Dockerfiles/proxy-sqlite3/rhel/docker-entrypoint.sh +++ b/Dockerfiles/proxy-sqlite3/rhel/docker-entrypoint.sh @@ -76,7 +76,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/proxy-sqlite3/ubuntu/docker-entrypoint.sh b/Dockerfiles/proxy-sqlite3/ubuntu/docker-entrypoint.sh index b531f12c9..ff96f708f 100755 --- a/Dockerfiles/proxy-sqlite3/ubuntu/docker-entrypoint.sh +++ b/Dockerfiles/proxy-sqlite3/ubuntu/docker-entrypoint.sh @@ -76,7 +76,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-mysql/alpine/docker-entrypoint.sh b/Dockerfiles/server-mysql/alpine/docker-entrypoint.sh index 9db32a922..4954c14de 100755 --- a/Dockerfiles/server-mysql/alpine/docker-entrypoint.sh +++ b/Dockerfiles/server-mysql/alpine/docker-entrypoint.sh @@ -109,7 +109,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-mysql/centos/docker-entrypoint.sh b/Dockerfiles/server-mysql/centos/docker-entrypoint.sh index f06144ba2..14c35ead6 100755 --- a/Dockerfiles/server-mysql/centos/docker-entrypoint.sh +++ b/Dockerfiles/server-mysql/centos/docker-entrypoint.sh @@ -109,7 +109,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-mysql/ol/docker-entrypoint.sh b/Dockerfiles/server-mysql/ol/docker-entrypoint.sh index f06144ba2..14c35ead6 100755 --- a/Dockerfiles/server-mysql/ol/docker-entrypoint.sh +++ b/Dockerfiles/server-mysql/ol/docker-entrypoint.sh @@ -109,7 +109,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-mysql/rhel/docker-entrypoint.sh b/Dockerfiles/server-mysql/rhel/docker-entrypoint.sh index f06144ba2..14c35ead6 100755 --- a/Dockerfiles/server-mysql/rhel/docker-entrypoint.sh +++ b/Dockerfiles/server-mysql/rhel/docker-entrypoint.sh @@ -109,7 +109,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-mysql/ubuntu/docker-entrypoint.sh b/Dockerfiles/server-mysql/ubuntu/docker-entrypoint.sh index f06144ba2..14c35ead6 100755 --- a/Dockerfiles/server-mysql/ubuntu/docker-entrypoint.sh +++ b/Dockerfiles/server-mysql/ubuntu/docker-entrypoint.sh @@ -109,7 +109,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-pgsql/alpine/docker-entrypoint.sh b/Dockerfiles/server-pgsql/alpine/docker-entrypoint.sh index 9ce3958e7..564d440ad 100755 --- a/Dockerfiles/server-pgsql/alpine/docker-entrypoint.sh +++ b/Dockerfiles/server-pgsql/alpine/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-pgsql/centos/docker-entrypoint.sh b/Dockerfiles/server-pgsql/centos/docker-entrypoint.sh index 9ce3958e7..564d440ad 100755 --- a/Dockerfiles/server-pgsql/centos/docker-entrypoint.sh +++ b/Dockerfiles/server-pgsql/centos/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-pgsql/ol/docker-entrypoint.sh b/Dockerfiles/server-pgsql/ol/docker-entrypoint.sh index 9ce3958e7..564d440ad 100755 --- a/Dockerfiles/server-pgsql/ol/docker-entrypoint.sh +++ b/Dockerfiles/server-pgsql/ol/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-pgsql/rhel/docker-entrypoint.sh b/Dockerfiles/server-pgsql/rhel/docker-entrypoint.sh index 9ce3958e7..564d440ad 100755 --- a/Dockerfiles/server-pgsql/rhel/docker-entrypoint.sh +++ b/Dockerfiles/server-pgsql/rhel/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path" diff --git a/Dockerfiles/server-pgsql/ubuntu/docker-entrypoint.sh b/Dockerfiles/server-pgsql/ubuntu/docker-entrypoint.sh index 9ce3958e7..564d440ad 100755 --- a/Dockerfiles/server-pgsql/ubuntu/docker-entrypoint.sh +++ b/Dockerfiles/server-pgsql/ubuntu/docker-entrypoint.sh @@ -110,7 +110,7 @@ update_config_var() { var_value=$(escape_spec_char "$var_value") var_name=$(escape_spec_char "$var_name") - if [ "$(grep -E "^$var_name=$var_value" $config_path)" ]; then + if [ "$(grep -E "^$var_name=$var_value$" $config_path)" ]; then echo "exists" elif [ "$(grep -E "^$var_name=" $config_path)" ] && [ "$is_multiple" != "true" ]; then sed -i -e "/^$var_name=/s/=.*/=$var_value/" "$config_path"