A man armed with a rifle died after being shot by police officers at an ICE detention center in Washington state that he had attempted to set on fire, authorities said.

An employee at the US Immigration and Customs Enforcement's Northwest Detention Center called Tacoma police around 4 a.m. Saturday, reporting a man outside with a rifle who was throwing incendiary devices.

A car in the parking lot was set on fire, and the man also threw the lit devices at buildings and attempted to ignite a propane tank, police said.

He was identified as 69-year-old Willem Van Spronsen, and ICE praised police in preventing any harm to staff or detainees.

"This could have resulted in the mass murder of staff and detainees housed at the facility had he been successful at setting the tank ablaze," Shawn Fallah of ICE's Office of Professional Responsibility said in a statement. "These are the kinds of incidents that keep you up at night."

When officers arrived at the scene early Saturday, they found the armed man and reported shots fired, according to a Tacoma Police Department press release.

The department said four officers were involved in the shooting and, per procedure, have since been placed on paid administrative duty.

After shots were fired, the officers retreated, then approached the man using cover, police said. He was found with at least one gunshot wound and pronounced dead at the scene, police said.

Investigation into the shooting is ongoing.

La Resistencia, a group that organizes protests of the detention center, said it believed that Van Spronsen was not targeting people at the facility but, rather, a fleet of buses that transport immigrants during deportation.

"His actions sadly reflect the level of desperation people across this country feel about the government’s outrageous violence against immigrants, which includes the use of detention centers to cage migrants both currently living in the U.S. and those seeking asylum," the group said in a statement.

A friend told the Seattle Times that Van Spronsen, whom she described as an anarchist and anti-fascist, sent a letter before the incident saying goodbye. She added she believed his actions were a form of suicide.

In 2018, Van Spronsen was one of 10 people arrested at a protest outside the detention center, the New Tribune reported. According to the newspaper, Van Spronsen was accused of jumping on a police officer as the officer was attempting to detain a 17-year-old; Van Spronsen later pleaded guilty to obstructing police.