Updated

Two U.S. military bases in Texas will be ordered by the Trump administration to house thousands of illegal immigrants who were detained crossing the southern border with Mexico, two U.S. officials tell Fox News.

The administration selected Fort Bliss and Goodfellow Air Force Base for the tent camps, Defense Secretary James Mattis confirmed during a Monday press conference.

"We'll provide whatever support the Department of Homeland Security needs in order to house the people that they have under their custody," Mattis said.

One of the bases will house both migrant adults and children, and the other will house only unaccompanied minors, according to one official.

Last week, the Pentagon agreed to house up to 20,000 unaccompanied minors after receiving a request from the Department of Health and Human Services. According to DHS, roughly 80 percent of children who come to the southern border arrive unaccompanied.

On Friday, the Pentagon said it was looking for bases to house adults as well. It considered three bases in Texas and one in Arkansas.

TRUMP SIGNS EXECUTIVE ORDER TO STOP FAMILY SEPARATIONS AT BORDER

Mattis said on Sunday that two bases had been selected, but he would not identify them.

Under the arrangement, the Defense Department would provide the land, but the operations would be run by other agencies.

It comes a week after President Trump said flatly, "The United States will not be a migrant camp and it will not be a refugee holding facility. Not on my watch."

But under the administration's current "zero tolerance" immigration policy, all unlawful crossings are referred for prosecution.

More than 2,300 minors were separated from their families at the border from May 5 through June 9, according to the Department of Homeland Security.

After an outcry over the separation of parents and children at the border, Trump on Wednesday signed an executive order to allow children to stay with parents caught crossing the border illegally.

Fox News’ Adam Shaw and The Associated Press contributed to this report.