– The Obama administration said Friday it will ask a judge to allow it to continue with plans to offer protection from deportation to millions of people living in the U.S. illegally.

Department of Justice lawyers plan to file a motion by Monday requesting that a federal judge in Texas stay his order that temporarily blocks President Obama's immigration programs, White House spokesman Josh Earnest said.

If the judge, Andrew Hanen, denies the request, as many legal experts expect, the administration could file an appeal with the Fifth Circuit Court of Appeals and later the U.S. Supreme Court.

A federal judge has issued a temporary injunction Friday halting another facet of the Obama administration's immigration policy: locking up immigrant mothers and children applying for asylum in order to deter others from illegally crossing the border.

In a 40-page opinion, U.S. District Judge James Boasberg said the government's policy of using deterrence as a reason to detain the immigrants instead of releasing them while their asylum claims were being processed was "likely unlawful."

Boasberg ordered federal officials to stop detaining asylum seekers "for the purpose of deterring future immigration to the United States, and from considering deterrence of such immigration as a factor" in their decisions until a final ruling is made on the policy.

Hanen issued the order Monday in a lawsuit filed by Texas and two dozen other states, mostly led by Republicans. They sued to block the president's move last year to use his executive authority to shield from deportation about half of the 11 million people living in the U.S. illegally.

Immigrants who qualify would get a three-year permit to stay in the country.

In his order blocking administration moves on Monday, Hanen said Obama overstepped his legal authority.

The administration cannot "enact a program whereby it not only ignores the dictates of Congress but actively acts to thwart them," Hanen ruled.

But he based his injunction on narrow legal grounds, saying that the underlying constitutional issues needed a full hearing and that his ruling would preserve the status quo in the meantime.

The decision by Hanen created a stumbling block for the administration's plans.

The first piece of the immigration program was due to roll out this week but has been put on hold. The biggest part of the program, which would cover up to 4 million adults who have been in the country since 2010, was scheduled to open to applicants in May.

Despite the ruling, Obama made it clear that the administration would press ahead with preparations for the immigration programs.

"We are doing the preparatory work because this is a big piece of business," Obama told reporters this week.