diff --git a/noderedeploy.sh b/noderedeploy.sh index 38379a8..b36b1a9 100644 --- a/noderedeploy.sh +++ b/noderedeploy.sh @@ -32,8 +32,8 @@ if [ ! -d "/usr/local/goedge" ]; then unzip -o edge-node-linux-amd64-plus.zip # Create or overwrite api_node.yaml from the template - if [ -d "$edge_node_path/configs" ]; then - cp "$edge_node_path/configs/api_node.template.yaml" "$edge_node_path/configs/api_node.yaml" + if [ -d "./configs" ]; then + cp "./configs/api_node.template.yaml" "$edge_node_path/configs/api_node.yaml" else echo "Configuration directory does not exist. Exiting." exit 1 @@ -44,7 +44,6 @@ if [ ! -d "/usr/local/goedge" ]; then read -p "Enter rpc.endpoints: " rpc_endpoints read -p "Enter nodeId: " node_id read -p "Enter secret: " secret - # Insert configuration into api_node.yaml echo "rpc.endpoints: [\"$rpc_endpoints\"]" > "$edge_node_path/configs/api_node.yaml" echo "nodeId: \"$node_id\"" >> "$edge_node_path/configs/api_node.yaml"