Authorities just released surveillance video showing what happened outside the Florida high school during the shooting

Surveillance video released Thursday appears to show the school resource officer Scot Peterson standing outside the freshman building during the February 14 shooting in Parkland, Florida.Twitter/@CBS12

The Broward County Sheriff's Office released surveillance video Thursday showing what happened outside the building where last month's Florida shooting took place.

The video appears to show an armed deputy standing outside the building for several minutes and not entering.

The deputy Scot Peterson resigned after an investigation by the sheriff's office found that he did "nothing" instead of confronting the gunman.

A newly released video appears to show that an armed school resource officer remained outside a Marjory Stoneman Douglas High School building during the shooting that left 17 people dead.

The video was released at noon Thursday, just over a month after the February 14 attack in Parkland, Florida, after multiple media organizations sued for access, arguing that the public had a right to know what happened.

A judge granted that request, and neither the school district nor the Broward County Sheriff's Office appealed the ruling.

A Broward County sheriff's deputy, Scot Peterson, resigned in disgrace roughly a week after the shooting after an investigation found he waited outside the school and made no attempt to confront the gunman, though his lawyer disputed accusations that Peterson failed to follow protocol or acted cowardly.

"The video speaks for itself," the sheriff's office said in a statement on Thursday. "His actions were enough to warrant an internal-affairs investigation, as requested by Sheriff Scott Israel on February 21. After being suspended without pay, Peterson chose to resign and immediately retired rather than face possible termination."

Watch a clip of the video below:

According to a timeline released earlier by authorities, the shooting started at roughly 2:21 p.m.

The video shows two people running toward Building 12 at 2:23 p.m., but as one of them appears to run into the building, the other, believed to be Peterson, hangs back and talks on his radio for several minutes.

Starting at about the 1:30-minute mark of the video, the remaining man, whom authorities have identified as Peterson, can be seen standing at the top left-hand corner of the frame, though a utility post blocks the view of him for parts of the video.

A few days after the attack, Broward County Sheriff Scott Israel told the news media that Peterson did "nothing" when he should have gone into the building and "addressed the killer — killed the killer."

Peterson's lawyer has said Peterson decided not to enter the building where the shooting took place because he believed the gunfire was outdoors.

But internal radio dispatches released last week appeared to contradict that defense, as Peterson could be heard telling dispatchers that the gunfire was coming from "inside the 1200" building and warning fellow deputies to stay at least 500 feet away from the scene.

It ultimately took 11 minutes after the shooting began before any authorities entered the building. By that point, the suspect, Nikolas Cruz, is believed to have already fled the school by blending into a crowd of students.

Prosecutors announced on Tuesday that they intended to seek the death penalty for Cruz. A grand jury indicted him on 34 counts — 17 for first-degree murder and 17 for attempted first-degree murder.

Cruz appeared in court on Wednesday — the same day thousands of students across the US conducted school walkouts protesting gun violence — and kept his head bowed as he was formally arraigned.