The explosion in al-Shaire district in Khost came two days after the province's deputy intelligence director was shot dead in broad daylight while on his way to work.
Khost district chief Lutf Allah said the bomb exploded at 9am in a ground floor shop of the building which has a military post on the upper floor.
"This bomb was planted by al-Qaida and Taliban in the shop and their aim was to kill soldiers on the second floor," Lutf Allah said.
"In the explosion one soldier died, one soldier was injured and the shopkeeper also died and five other civilians were injured," the official added.
More than 20 rockets landed near a US-led military base in Khost overnight, prompting the US-led coalition force to bomb the area, officials said.
"At about midnight last night, approximately 20 rockets impacted in the vicinity of our base in Khost. After checking for civilian structures in the vicinity of the launch point, we returned fire with artillery and precision guided bombs"
Lt Col Bryan Hilferty
US military spokesman
"At about midnight last night, approximately 20 rockets impacted in the vicinity of our base in Khost," US military spokesman Lieutenant Colonel Bryan Hilferty said, adding there were no casualties.
"After checking to ensure there were no civilian structures in the vicinity of the launch point, we did return fire with artillery and precision guided bombs. At this time there is no indication of anti-coalition militia casualties."
The rockets were fired on Friday morning near the US base in Khost, some 150km southeast of Kabul, military commander Khial Baz Khan said.
"Some 21 rockets were fired but fortunately none of them caused any casualties," he said.
Khost, a key province and city in southeastern Afghanistan, has frequently been subjected to attacks by suspected rebels believed to be regrouping on the other side of the border in Pakistan.
Khost deputy intelligence director Muhammad Isa was shot dead on Wednesday by a suspected Taliban guerrilla who later blew himself up.
A Taliban spokesman has claimed responsibility for Wednesday's attack, saying the intelligence director was targeted because he had given information to US forces and was formerly a member of an Afghan communist party.
The south and southeast of Afghanistan is the former stronghold of the Taliban and remnants of the regime and their al-Qaida allies are active in the region.