FBI Director James Comey testifies before a House committee Sept. 28, 2016.

The decision by FBI Director James Comey to reopen the investigation into Hillary Clinton’s email server and her mishandling of classified material came after he could no longer resist mounting pressure by FBI agents described as “mutinous.”

In an article for Britain’s Daily Mail, bestselling author Ed Klein reports some of Comey’s top deputies were in on the mutiny, according to a source close to the director.

“The atmosphere at the FBI has been toxic ever since Jim announced last July that he wouldn’t recommend an indictment against Hillary,” said the source, who Klein says has known Comey for nearly 20 years and spends family outings together.

“Some people, including department heads, stopped talking to Jim, and even ignored his greetings when they passed him in the hall,” said the source. “They felt that he betrayed them and brought disgrace on the bureau by letting Hillary off with a slap on the wrist.”

The source says Comey agonized over the issue for months and even talked about it with his wife, Patrice.

James Comey, left, gets sworn in as FBI director as his wife Patrice, center, looks on

Comey told Patrice the stack of resignation letters from livid agents was making him depressed, as they reminded him that morale at the bureau had hit rock bottom.

“He’s been ignoring the resignation letters in the hope that he could find a way of remedying the situation,'” said the source, according to Klein.

“When new emails that appeared to be related to Hillary’s personal email server turned up in a computer used by [her close aide] Huma Abedin and [Abedin’s disgraced husband,] Anthony Weiner, Comey jumped at the excuse to reopen the investigation.

“The people he trusts the most have been the angriest at him. And that includes his wife, Pat. She kept urging him to admit that he had been wrong when he refused to press charges against the former secretary of state.”

“He talks about the damage that he’s done to himself and the institution [of the FBI], and how he’s been shunned by the men and women who he admires and work for him. It’s taken a tremendous toll on him. It shattered his ego. He looks like he’s aged 10 years in the past four months.”