The former Wright City R-II superintendent likely will spend the rest of his life in prison for murdering a Springfield couple.

Mark E. Porter, 54, of Ozark, pleaded guilty last week to two counts of second-degree murder in the deaths of 60-year-old Gary Tyrrell and his wife, 61-year-old Jan Tyrrell.

The Tyrrells were found dead in their home in May 2014 after relatives reported they had not been able to contact the couple. Gary Tyrrell had been shot twice, and Jan Tyrrell had been bludgeoned to death.

Porter, a friend of the couple, agreed to two consecutive life terms and will avoid the death penalty as part of a plea agreement.

Porter had previously been charged with two counts of first-degree murder.

His involvement in the double-homicide shocked many in the Wright City community.

He served as superintendent in the R-II school district from 2005 to 2008. He retired from the district to begin working in the private sector and moved out of the area.

Prior to working in Wright City, Porter was superintendent in the Mountain Grove school district where Gary Tyrrell was his assistant.

Prosecutors said the murder was spurred by Porter’s gambling problem, according to published reports.

Initially, Porter told police that he was not in any financial trouble. He told police he was paid a $275,000 salary and received additional bonuses at his job with IBM and he also received a pension from being a school superintendent, The Springfield News-Leader reported.

But he eventually told police he and his wife had a total debt of $250,000.

That was the same amount Porter sought when he approached Gary Tyrrell for a loan, according to charging documents.

Gary Tyrrell dealt in precious metals and gemstones and the couple’s home was filled with high-end items, police said. The couple and Porter were longtime friends and Porter was one of the few people allowed into their home.

Officers discovered the couple’s bodies after their daughter reported she had been unable to contact them. Police said they found no signs of forced entry at the home.

Investigators also discovered Porter had sold $18,531 in silver coins the day after the couple’s bodies were found, and documents in the Tyrrells’ home showed they had silver coins valued at $22,000.

Investigators linked Porter to the crime when DNA on a latex glove found near Jan Tyrrell’s body matched DNA on a coffee cup that had been discarded by Porter and retrieved by an undercover officer, according to the court documents filed by prosecutors.

The Associated Press contributed to this story.