Ceiling lamp cup

I had trouble finding a replacement for an old ceilng lamp cup (don't exactly know if this is the right name for it) after the original one got broken, and so I printed myself one...

I don't know if this design will be of any use to anyone else, but since it solved a problem for me, perhaps it will help someone else as well.

UPDATE: Added a couple of pictures of the cup in its final placement!