Remove fixed username references

This commit is contained in:
David Boreham 2024-08-06 07:39:49 -06:00
parent 202436dc2b
commit c3264deaeb

View File

@ -23,7 +23,7 @@ for (( i=1 ; i<=$node_count ; i++ ));
do
node_name=${machine_name_prefix}-${i}
node_host_name=${node_name}.${machine_domain}
gentx_file_name=$(ssh ${ssh_user}@${node_host_name} ls /home/laconic/${gentx_dir} | head -1)
gentx_file_name=$(ssh ${ssh_user}@${node_host_name} ls ${gentx_dir} | head -1)
node_id=$(echo ${gentx_file_name} | sed -e 's/^gentx-//' -e 's/.json$//')
node_ip=$(dig +short ${node_host_name})
peer=${node_id}@${node_ip}:${p2p_port}
@ -42,8 +42,8 @@ do
node_name=${machine_name_prefix}-${i}
node_host_name=${node_name}.${machine_domain}
echo "Copying ${gentx_dir} on ${node_name} to ${local_gentx_dir}"
scp laconic@${node_host_name}:~/${gentx_dir}/* ${local_gentx_dir}
scp laconic@${node_host_name}:~/${genesis_json_file} ${local_gentx_dir}/${node_name}-genesis.json
scp ${ssh_user}@${node_host_name}:~/${gentx_dir}/* ${local_gentx_dir}
scp ${ssh_user}@${node_host_name}:~/${genesis_json_file} ${local_gentx_dir}/${node_name}-genesis.json
done
# Extract the peer node validator addresses from their genesis.json files
@ -61,9 +61,9 @@ echo "Copying gentx files to node 1"
node_1_host_name=${machine_name_prefix}-1.${machine_domain}
ssh ${ssh_user}@${node_1_host_name} rm -rf ${local_gentx_dir}
ssh ${ssh_user}@${node_1_host_name} mkdir ${local_gentx_dir}
scp ${local_gentx_dir}/gentx-* laconic@${node_1_host_name}:~/${local_gentx_dir}
scp ${local_gentx_dir}/gentx-* ${ssh_user}@${node_1_host_name}:~/${local_gentx_dir}
gentx_file_list=$(ssh laconic@${node_1_host_name} ls -m ${local_gentx_dir}/gentx-*)
gentx_file_list=$(ssh ${ssh_user}@${node_1_host_name} ls -m ${local_gentx_dir}/gentx-*)
echo "Node 1 now has: ${gentx_file_list}"
gentx_files=$(echo ${gentx_file_list} | tr -d ' ' | tr -d '\n')