I have a similar situation. I've been looking at the rubyzip library but it apparently does not support the compression of streams nor does it do in memory zipping. It seems to only work directly with files.
I'd be interested to know if you got anywhere with this?