I am using linux bash shell. I want to return value from ssh while using EOF.I am new to this.
result=$(ssh -T -q -o UserKnownHostsFile=/dev/null -o
StrictHostKeyChecking=no -o ConnectTimeout=60 -o ConnectionAttempts=3 ${host_name} << EOF
echo "Get details in mysql"
EOF 2>/dev/null)
This gives error saying
unexpected EOF while looking for matching `)'
In my actual usecase i have somany commands to run on remote host and get results. So i will have somany linux commands in between EOF