Script Assistance - Outputting to file with Awk

I'm trying to take a list of domains, find out the MX resolve it to IP then find out what the NS is and output the contents to a new file.

The only problem i'm having is when checking the Ip or host of the MX i can only get it to print the column with the MX record and the results of the host check.

How do i print out the entire contents of the line that the MX was checked from?

The line in bold is the section i'm having an issue with

dig -f domains.txt mx | grep -i comcast | grep -v \; | grep MX | awk '{print $1 " " $6}' > mx.txt
grep -e comcast mx.txt | awk '{print "host " $2}' | sh > mxhost.txt
dig -f mx.txt ns | grep -v \; | grep NS | awk '{print $1 " " $5}' > nshost.txt
cat mxhost.txt nshost.txt > host.txt

this is the output i am getting

mx2.businessclass.comcast.net has address 76.96.53.25
mx1.businessclass.comcast.net has address 76.96.53.25
mx1.businessclass.comcast.net has address 76.96.53.25
mx2.businessclass.comcast.net has address 76.96.53.25
inbound.burnscompany.net.cust.comcastmailservice.com has address 76.96.53.25
inbound.cameroninc.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.full-focus.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.bayfr.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.bgctrenton.org.cust.comcastmailservice.com has address 76.96.53.25
inbound.bhamplc.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.bigideaonline.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.bmxmed.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.bocabayfinancial.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.bowerseq.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.burdettelawfirm.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.camezchurch.org.cust.comcastmailservice.com has address 76.96.53.25
inbound.bmxmed.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.caroldavis.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.carpenburymed.com.cust.comcastmailservice.com has address 76.96.53.25
inbound.carverheightschurch.org.cust.comcastmailservice.com has address 76.96.53.25
inbound.cathcart-cunnison.com.cust.comcastmailservice.com has address 76.96.53.25

This is what i want to achieve... any ideas?

domain.com mx2.businessclass.comcast.net has address 76.96.53.25
domain.com mx1.businessclass.comcast.net has address 76.96.53.25
domain.com mx1.businessclass.comcast.net has address 76.96.53.25
domain.com mx2.businessclass.comcast.net has address 76.96.53.25
domain.com inbound.burnscompany.net.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.cameroninc.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.full-focus.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bayfr.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bgctrenton.org.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bhamplc.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bigideaonline.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bmxmed.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bocabayfinancial.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bowerseq.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.burdettelawfirm.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.camezchurch.org.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.bmxmed.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.caroldavis.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.carpenburymed.com.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.carverheightschurch.org.cust.comcastmailservice.com has address 76.96.53.25
domain.com inbound.cathcart-cunnison.com.cust.comcastmailservice.com has address 76.96.53.25

Where does "domain.com" come from?

The bolded line has something funny in it. Try this:

awk '/comcast/ {print "host " $2}' mx.txt > mxhost.txt