Ligon Middle School was locked down for about two hours Thursday morning after a teen brought a gun to the school, police said.