One deputy was killed and a second was wounded in a shootout and pursuit in Spartanburg County, South Carolina, Tuesday afternoon, Spartanburg County Sheriff Chuck Wright said. The suspect was arrested.

The deputy was shot and killed while responding to a domestic violence call at about 3:20 p.m., Wright said.

“He was ambushed, and he was shot,” Wright said in a news conference. The deputy, a three-year veteran of the department, was not immediately publicly identified.

According to Wright, after shooting the deputy, the male suspect got into a vehicle and tried to speed away, but crashed.

“Guy gets in a car, they chase him again, he wrecks, gets out and fires at the (second) deputy,” Wright said.

The second deputy was struck twice by gunfire, but is expected to survive, Wright said.

A SWAT team eventually moved in and took the suspect into custody, Wright said. The suspect’s name was not released.