(CNN) - A man was shot Friday after police say he opened fire at a hospital in Bakersfield, California.
Police responded to the Bakersfield Heart Hospital after they received reports of an active shooter.
Assistant Police Chief Greg Terry said the suspect first fired several shots into a glass door at the rear of the building and then entered the hospital with a handgun and an assault rifle.
The man was confronted by a security officer but no shots were fired.
Shortly after, the suspect exited the hospital and was shot by police, Terry said.
The suspect, who was not identified, was being treated at a local hospital Friday night and was in stable condition, officials said.
No patients, staff or visitors were injured during the incident, police said.
The gunman's motive remains unclear but authorities believe terrorism was not a factor in the shooting, said FBI supervisory special agent Jose Moreno.
The hospital went on lockdown after a housekeeper alerted administrators that a person with a firearm was in the back parking lot, the hospital's CEO Michelle Oxford said.
Ronnie Nop and his 8-year-old son were visiting a family member in the hospital's intensive care unit when the hospital when on lockdown. As they were taking cover in an empty room, Nop said he saw the gunman running outside the building.
This story has been updated to correct the condition of the suspect. He was hospitalized Friday night and is in stable condition, authorities said.
Copyright 2017 by CNN NewSource. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.