(Reuters) - A man accused of acting as a lookout while two fellow inmates at a federal prison killed the notorious Boston mobster James "Whitey" Bulger in his cell in 2018 was set to be released from custody after a judge on Monday sentenced him to time served.

Sean McKinnon, 38, was sentenced by U.S. District Judge Thomas Kleeh in Clarkburg, West Virginia, after he and the other two inmates last month reached plea deals to resolve charges filed against them in 2022 over Bulger's death, prosecutors said.

As part of his plea deal, prosecutors dropped the most serious charge against McKinnon, conspiracy to commit first degree murder, and he pleaded guilty to lying to an FBI agent when he claimed he did not know what happened to Bulger.

His sentence reflected the time McKinnon had served since his arrest in August 2022. Unlike the other two defendants, Paul DeCologero and Fotios "Freddy" Geas, McKinnon was already out of prison by the time of his indictment.

Further plea and sentencing hearings are scheduled for Aug. 1 for DeCologero and Sept. 6 for Geas. McKinnon's lawyers did not respond to requests for comment.

Bulger lived a double life as one of Boston's most notorious mobsters while also acting as a secret FBI informant. He went on the run for 16 years after he was tipped off by his FBI handler about a pending racketeering indictment against him.

Bulger was captured in California in 2011. Two years later he was convicted for 11 murders and other offenses and was sentenced to life in prison.

The 89-year-old's murder took place hours after he had been transferred from a prison in Florida.

At the time of Bulger's death, Geas was serving a life term for the 2003 murders of Genovese crime family boss Adolfo "Big Al" Bruno and associate Gary Westerman. DeCologero was serving a sentence of life plus 25 years for murder, racketeering and firearms offenses.

McKinnon was serving an eight-year sentence for stealing guns from a Vermont firearms store and was Gaes' cellmate.

Prosecutors said the morning after Bulger arrived in the prison, Geas and DeCologero on Oct. 30, 2018, went to Bulger's cell and Geas beat him to death.

Prosecutors had previously said that McKinnon during the incident sat at a table looking at Bulger's cell. When questioned, he said he knew nothing about what happened, prosecutors said.

Bulger's body was not discovered by prison officials for nearly two hours. Other inmates later reported some of the men said Bulger had been killed because he was a "snitch," prosecutors said.

(Reporting by Nate Raymond in Boston; Editing by Bill Berkrot)

By Nate Raymond