The husband of a city correction captain suspended for a vile, anti-police rant posted to the couple’s shared Facebook page is also a public employee, maintaining subway cars for the MTA, The Post has learned.

Rashid Stanley works as a car inspector for the MTA’s New York City Transit, according to sources — but that apparently didn’t stop him from unleashing the hateful social media tirade against his fellow civil servants.

“F–K THE POLICE…. ITS TIME WE SHOOT BACK!!! COP KILLERS STAND UP!!!!” reads part of the all-caps diatribe posted to the joint account of Stanley and his Rikers Island-assigned wife, Capt. La Shonda Stanley.

The vitriolic post is signed “Mr. Stanley,” and La Shonda Stanley didn’t hesitate to throw her not-so-better half under the bus.

“I didn’t make those comments,” La Shonda Stanley previously told The Post. “That’s my husband’s comment.”

The screed surfaced amid — and makes reference to — a string of water-bucket ambushes on uniformed NYPD officers.

“Y’ALL UPSET ABOUT SOME PIGS GETTING WATER THROWN ON THEM,” it reads. “THEY’RE LUCKY THEY DIDN’T GET SHOT WHILE MAKING AN ARREST! ALL THE INNOCENT BLACK MEN AND WOMEN KILLED AT THE HANDS OF THESE PIGS.”

Whether the post was made by Capt. Stanley or her husband made little difference to the city Department of Correction, which suspended her pending an investigation, as cops seethed over the perceived betrayal.

Rashid Stanley has worked for the MTA since at least 2017, pocketing $69,722 last year, according to public records.

“We are deeply troubled by the threatening language in the post,” said a statement from NYCT head Andy Byford, though the MTA didn’t say whether Stanley had been disciplined. A message left for Stanley was not returned.

Additional reporting by David Meyer