An auto theft suspect who was recorded being beaten by Alameda County sheriff’s deputies in a Mission District alley in November was arrested Friday afternoon as FBI and San Francisco police raided a Visitacion Valley house he was in — the same site where a man was shot earlier in the day.

Stanislav Petrov, 29, was taken into custody after FBI agents and police served a warrant at a house on Teddy Avenue around 3 p.m., said Prentice Danner, an FBI spokesman. Around 6:50 p.m., federal agents were seen handcuffing and taking away a man and a woman. Officials said multiple people, possibly four in total, were arrested.

Neighbors say the house is frequented by Petrov, the man seen in a widely circulated video being beaten with batons by two deputies on Stevenson Street after he crashed his car and ran after a cross-bay chase.

Police on the scene Friday said the FBI action was related to a 2 a.m. shooting in front of the house. Danner said Petrov’s complaint was still sealed, so his charges were not immediately known.

The shooting victim, a 27-year-old man, was standing outside the house when four to five shots were fired. Neighbors said the man fell to the ground in the gutter and was picked up by three men, put into a silver BMW and driven away.

“We’ve got to get him out of here. We’ve got to get him out of here. The cops are coming,” a neighbor, who spoke anonymously to The Chronicle, said he heard the men yelling.

Police officials confirmed the man was shot multiple times in his upper body and driven to a hospital by friends. Police said the victim, whose name was not released, had life-threatening injuries.

It was unclear whether a man and woman taken into custody were arrested in the shooting.

Petrov arrived at the house Friday afternoon while a Chronicle reporter was there but said he knew nothing about the shooting.

Asked if he was one of the men who drove the victim to the hospital, Petrov said, “That’s completely incorrect.” He walked into the house and shut the door.

Two Alameda County deputies were placed on paid leave after the November release of surveillance video showed one of them tackling Petrov and punching him twice while he was on the ground. The second deputy then pulled out his baton and struck Petrov on the head. The video jumped 10 seconds to show both deputies hitting Petrov repeatedly with their batons as he struggled on his knees and screamed for help.

Officials said the beating occurred after deputies spotted Petrov in a stolen car and chased him from Castro Valley over the Bay Bridge and into San Francisco. The deputies said in reports that Petrov had rammed two patrol cars and that they feared he was armed, possibly on drugs and dangerous.

The beating sparked public outcry. Upon learning of the video, Alameda County Sheriff Gregory Ahern opened an internal investigation. The incident is also being investigated by San Francisco police and the San Francisco district attorney.

On Tuesday, Michael Haddad, a civil rights attorney, filed a claim against Alameda County on behalf of Petrov, alleging deputies used excessive force. The claim, a legal precursor to a suit, also contends that a third deputy stole a gold chain and medallion and cash from Petrov and gave it to some homeless witnesses to buy their silence.

Petrov is expected in court Monday for an initial appearance in his Friday arrest.

Chronicle staff writer

Michael Cabanatuan contributed to this report.

Jenna Lyons and Hamed Aleaziz are San Francisco Chronicle staff writers. Email: jlyons@sfchronicle.com, haleaziz@sfchronicle.com Twitter: @JennaJouno @haleaziz