Subversion Repositories ALCASAR

Rev

Rev 3318 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 3318 Rev 3321
Line 101... Line 101...
101
/usr/sbin/useradd -s /bin/sh -m "$REPL_USER"
101
/usr/sbin/useradd -s /bin/sh -m "$REPL_USER"
102
echo -e "$REPL_PWD\n$REPL_PWD" | passwd "$REPL_USER"
102
echo -e "$REPL_PWD\n$REPL_PWD" | passwd "$REPL_USER"
103
mkdir "/home/$REPL_USER/.ssh"
103
mkdir "/home/$REPL_USER/.ssh"
104
touch "/home/$REPL_USER/.ssh/authorized_keys"
104
touch "/home/$REPL_USER/.ssh/authorized_keys"
105
chown replication:replication -R "/home/$REPL_USER/.ssh"
105
chown replication:replication -R "/home/$REPL_USER/.ssh"
106
echo $REPL_DB_PWD > /home/$REPL_USER/db_replication_user_pass.txt
106
echo $REPL_DB_PWD > /home/$REPL_USER/local-db_replication-pwd.txt
107
chown $REPL_USER:$REPL_USER /home/$REPL_USER/db_replication_user_pass.txt; chmod 400 /home/$REPL_USER/db_replication_user_pass.txt
107
chown $REPL_USER:$REPL_USER /home/$REPL_USER/local-db_replication-pwd.txt; chmod 400 /home/$REPL_USER/local-db_replication-pwd.txt
108
 
108
 
109
# Generate user SSH key
109
# Generate user SSH key
110
if ! ls ~/.ssh/id_* &> /dev/null
110
if ! ls ~/.ssh/id_* &> /dev/null
111
then
111
then
112
	echo "Generating SSH key..."
112
	echo "Generating SSH key..."