A Rapid City police officer justifiably believed that his life was in danger when he shot and killed a man at an apartment complex in November, South Dakota Attorney General Marty Jackley said Thursday.

Jackley said a Division of Criminal Investigation review found the man, James Mathew Murphy, rushed at the officer with a knife and struggled with him before he was shot.

SOUTH DAKOTA AG MARK VARGO CLEARS SIOUX FALLS POLICE OFFICER FOR SHOOTING

Pierre, Deadwood, Sioux Falls crime

South Dakota officials determined that the November shooting of a suspect by a Rapid City police officer was justified.

"The officer attempted to deescalate the situation but the individual they encountered continued with threatening behavior," Jackley said. "This was a justified use of lethal force by the officer."

SOUTH DAKOTA MAN WHO FLED FROM POLICE SHOOTING ARRESTED

Video and audio recordings from the officer’s body worn camera, witness interviews, surveillance video and other forensic evidence corroborated the officer’s account that he feared for his life and that Murphy was a danger to the public, Jackley said.

CLICK HERE TO GET THE FOX NEWS APP

The officer was not injured.