This tested and fit a ½" electrical box. I printed in PLA for indoor use, but I would use PETG for outdoor. I haven't tested this for water tight but it is similar in design from what you get off of Amazon which claims to be water tight.
The bottom socket, I tested to fix a thread ½" threaded electrical box.
The stl also included a threaded plug incase your electrical box have some unwanted openings.
I did not add any support for printing.
Remember tight is tight, too tight is broken.
The author marked this model as their own original creation.