CANNON BALL, N.D. —Most of the Dakota Access pipeline opponents abandoned their protest camp Wednesday ahead of a government deadline to get off the federal land, and authorities moved in to arrest others who defied the order in a final show of dissent.

The camp has been home to demonstrators for nearly a year as they tried to thwart construction of the pipeline. Many of the protesters left peacefully, but police began making arrests two hours after the deadline.

Earlier in the day, some of the last remnants of the camp went up in flames when occupants set fire to makeshift wooden housing as part of a leaving ceremony.

As many as 75 people outside the camp started taunting officers, who brought five large vans to the scene. Police took at least nine people into custody for failing to heed commands to leave, authorities said.

With darkness falling, Lt. Tom Iverson said police would not enter the camp Wednesday evening, but he offered no timetable for doing so.

Levi Bachmeier, an adviser to Gov. Doug Burgum, said about 50 people remained in the camp at dusk.

Hours before, about 150 people marched arm-in-arm out of the soggy camp, singing and playing drums as they walked down a highway. It was not clear where they were headed. One man carried an American flag hung upside-down.

Authorities sent buses to take protesters to Bismarck, where they were offered fresh clothing, bus fares home and food and hotel vouchers.

The U.S. Army Corps of Engineers set the deadline, citing the threat of spring flooding.

At the height of the protests, the site known as Oceti Sakowin hosted thousands of people, though its population dwindled to just a couple of hundred as the pipeline battle moved into the courts.

The camp is on federal land in North Dakota between the Standing Rock Sioux Reservation and the pipeline route that is being finished by Dallas-based Energy Transfer Partners. When complete, the project will carry oil through the Dakotas and Iowa to a shipping point in Illinois.

Some of the protesters were focused on moving off federal land and away from the flood plain, said Phyllis Young, one of the camp leaders.

“The camps will continue,” she said. “Freedom is in our DNA, and we have no choice but to continue the struggle.”

New camps are popping up on private land, including one the Cheyenne River Sioux set up about a mile from the main camp.

“A lot of our people want to be here and pray for our future,” tribal Chairman Harold Frazier said.

Others, including Dom Cross, an Oglala Sioux from Pine Ridge, South Dakota, said he planned to return home after living at the camp for six months.

“There’s a lot of sadness right now. We have to leave our second home,” he said.