City Districts give 15 housing, not 10. And more assuming you stack housing requirement reductions...
Combining communal, fertile and byzantine bureaucracy let's you decrease housing needs by 30%. The Red option from the Alien Box event let's you decrease it by 5% more (for primary species). And if you have Caravaneers they sometimes give you a Bunk Beds deployment, increasing planetary housing by 10%.
They can also give you +2 extra districts - which appears to be unlimited. Mastery of Nature also adds 2.
That's between 589 (No Alien Box) and 634 pops before adding more districts (most I've gotten is +6...).
At this point, jobs are a bigger concern than housing. If you fill up everything with Commerce Megaplexes you'll have 165 (1 merchant, 10 clerks, times 15 slots) jobs +8 from a fully upgraded capital.
You get 5 clerks from urban districts, which is too little to cover the extra housing... So you build more foundry districts.
Entertainment districts are unnecessary with this many clerks, and trade power should give you enough Consumer Goods to break even.
With the above bonuses (assuming no Alien Box, but with Bunk Beds) Every foundry district will provide enough housing for... ~15.71 pops.
We get 10 from the capital, so we can substract that from the 173 jobs we get from buildings.
Divided by the 5.71 surplus housing we get from foundry districts that means we only need... ~28 foundry districts to cover all the housing needs. That's almost possible with Mastery of Nature alone, or with Caravaneer RNG.
Assuming we manage that, you end up with 840 alloys base production per ecumenopolis, before taking into account modifiers.
Safe to say, getting a 1,000 is easily doable, though you're going to need a lot of minerals for that...