Giudice said he could not challenge that status while serving his sentence at Fort Dix because the South Jersey prison doesn’t allow inmates to appear before an immigration judge.

But in a filing earlier this month, a federal prosecutor argued Guidice’s complaint was moot because he’s being moved to a prison where he can challenge his immigration status.

The transfer to a prison in Allenwood, Pa., was expected to take place "in the coming days," Assistant U.S. Attorney Jessica O'Neill said in a Nov. 6 filing in federal court, Camden.

Giudice, 47, is servng a 41-month sentence for conspiring to commit mail and wire fraud and other crimes.

His participation in the Residential Drug Abuse Program (RDAP) could trim up to a year from a term set to end in March 2019, according to the federal Bureau of Prisons website.

According to a court filing, Giudice told an RDAP screener he was drinking “two or three bottles of wine daily” and using marijuana “occasionally” before entering prison in March 2016. He also had a 2010 conviction for driving while intoxicated, the filing says.

In rejecting his application for the residential program, authorities said Giudice could not show he’d be able to complete the final phase of “community confinement.” They noted a detainer allowed immigration officials to take Giudice into custody for a deportation hearing after his release from prison.

O'Neill's filing said prison officials initiated Giudice’s transfer on Sept. 27, three weeks after he brought his court challenge.

Giudice currently is in the Metropolitan Detention Center in Brooklyn, according to the Bureau of Prisons website.

U.S. District Judge Noel Hillman has not yet ruled on the inmate’s complaint.

Giudice and his wife became celebrities through their appearances on the Real Housewives show, now in its eighth season on the Bravo channel.

Joe Giudice was sentenced in October 2014, but did not enter prison until his wife completed a 15-month term.

The Morris County couple were accused of falsifying loan applications and concealing assets during bankruptcy proceedings between 2001 and 2011.

Under a plea agreement, Joe Giudice admitted guilt to multiple counts of bankruptcy fraud. He also acknowledged failing to file a federal income tax return in April 2005 after making almost $245,000 in the previous year, court records say.

An attorney for Giudice, Jerard Gonzalez of Hackensack, could not be reached for comment.