summaryrefslogtreecommitdiffstats
path: root/geo-replication
diff options
context:
space:
mode:
Diffstat (limited to 'geo-replication')
-rw-r--r--geo-replication/src/peer_add_secret_pub.in4
-rwxr-xr-xgeo-replication/src/set_geo_rep_pem_keys.sh2
2 files changed, 3 insertions, 3 deletions
diff --git a/geo-replication/src/peer_add_secret_pub.in b/geo-replication/src/peer_add_secret_pub.in
index 04dee1b1ea1..aed93991e58 100644
--- a/geo-replication/src/peer_add_secret_pub.in
+++ b/geo-replication/src/peer_add_secret_pub.in
@@ -1,9 +1,9 @@
#!/bin/bash
if [ "$1" == "" ]; then
- home_dir=`echo $HOME`
+ home_dir=`getent passwd root | cut -d ':' -f 6`;
else
- home_dir=`getent passwd | grep $1 | cut -d ':' -f 6`;
+ home_dir=`getent passwd $1 | cut -d ':' -f 6`;
fi
if [ "$home_dir" == "" ]; then
diff --git a/geo-replication/src/set_geo_rep_pem_keys.sh b/geo-replication/src/set_geo_rep_pem_keys.sh
index 16c55ed0a49..7a7bcad25c2 100755
--- a/geo-replication/src/set_geo_rep_pem_keys.sh
+++ b/geo-replication/src/set_geo_rep_pem_keys.sh
@@ -20,7 +20,7 @@ function main()
exit 1;
fi
- home_dir=`getent passwd | grep $user | cut -d ':' -f 6`;
+ home_dir=`getent passwd $user | cut -d ':' -f 6`;
if [ "$home_dir" == "" ]; then
echo "No user $user found"