LOS ANGELES — An unemployed motorcycle mechanic who gunned down airport screening officers at Los Angeles International Airport in a 2013 attack that sent passengers running for their lives pleaded guilty Tuesday to murder and 10 other charges.

Paul Ciancia, 26, pleaded guilty to all 11 charges in the rampage that killed one officer and wounded two others and a teacher who was headed for a flight.

Ciancia, who showed no emotion during the hearing, was spared the death penalty by entering the plea, but he faces a mandatory life term in prison at his sentencing on Nov. 7. He said very little, mostly answering “yes” and “no” to questions posed by a judge.

Survivors of the attack and the family of the officer killed cried as prosecutors explained in detail how Ciancia carried out the Nov. 1, 2013, shooting, motivated by anger about security measures imposed on airline passengers by the U.S. Transportation and Security Administration.

Security cameras captured Ciancia opening fire on TSA agent Officer Gerardo Hernandez at a document-screening podium, wounding the 39-year-old married father of two.

As Ciancia went up an escalator to the main security screening area, he saw Hernandez move and returned to fire several more shots at point-blank range, killing Hernandez.

Ciancia then stalked more victims with a semi-automatic rifle in Terminal 3.

TSA agents Tony Grigsby and James Speer, shot as they helped move passengers to safety, attended the sentencing and told reporters later about a scene of sheer chaos in the airport.

Speer, 57, said he helped a shell-shocked passenger moving slower than others run down a hallway. Just as he thought they were safe, Speer saw a teacher named Brian Ludmer get shot in the calf.

“A split second before I could say, ‘Oh my God,’ I felt boom, boom in the back and upper left arm. I was thrown forward from the blast,” said Speer, who ran wounded into a convenience store to hide.

Speer hid behind a pillar as Ciancia moved through the terminal, asking people if they were TSA agents and letting them go when they said no.

Speer, who survived a gunshot wound to the shoulder, said he was satisfied that Ciancia would spend the rest of his life in prison and called it “the next best thing” to a death sentence.

Grigsby, who was shot in the ankle, said he felt numb sitting near Cianci during the hearing and that the plea deal has helped bring closure for his family, including his mother and sister, also TSA agents at the airport.

“I didn’t know whether to get up and run away or sit there. I didn’t know what to feel,” said Grigsby, 38. “I wouldn’t give him the pleasure of having anger. I’m not a victim of the situation. I made a decision to help people, and I stand by that decision.”

Police shot and wounded Ciancia in the terminal’s food court, hitting him four times. He was armed with a Smith & Wesson semi-automatic rifle he had bought seven months earlier.

Officers found a duffel bag Ciancia dropped that had ammunition inside and a handwritten note saying he wanted to kill at least one TSA officer but hoped to kill more.

Ciancia, who was living in the Los Angeles area after growing up in Pennsville, New Jersey, signed the note with his name, adding beneath it, “Pissed-off Patriot.”

Hernandez’s wife, Ana Machuca, declined to speak with reporters after Ciancia’s court hearing. But she told The Associated Press last week that no sentence would bring closure or peace for her family.

“My husband died, and my children lost their father,” she said. “There isn’t anything anyone can do for us.”