I'm not sure this is an answer, so much as a list of things to consider…
Simple rule - more gain, more buzz.
Guitar pickups are, by their very nature, susceptible to all kinds of interference - hum from fluorescent tubes, old-style CRT TVs etc & to a lesser degree, even assuming everything is properly earthed, the mains circuit itself.
Any fluctuation in the magnetic fields near you will be picked up by the pickups - that's pretty much what they do for a job. That's how they 'hear' the strings.
Adding any form of compression will reduce the dynamic range, turning down the maximum level & turning up the noise floor, hiss & hum.
In this respect an overdrive is also a compressor - one that will add its own self-generated noise too.
You can reduce the input noise by adding a noise gate before the pedal chain, but this will not prevent noise added by the signal chain itself - however, simply adding another gate at the end of the chain would come with its own problems. Varying combinations of effect pedal will produce different amounts of noise. Gating for the lowest noise might leave the gate open for most of the time in any other effect combination. Gating for the highest level might leave it closed when the entire chain is off, badly clipping notes.
The 'perfect' though expensive & really really irritating solution would be to have a gate between each effect, & add the gate as you switch the corresponding effect on.
Not really a practical solution ;)
Another way to eliminate the input hum entirely would be to use something like a Line6 Variax - which has no magnetic pickups & therefore is immune to electro-magnetic interference… wouldn't help with the pedal noise itself, though.