A magnetic latch and knob I made for my printer door. The magnets are 5mm diameter ball type and I use two per latch to increase the pull a bit. The magnet contacts with the screw head that mounts the knob. They must be well lined up which is pretty easy with a clear door. Has enough pull to hold the door shut but opens very easily. If you want it to hold very securely then this isn't for you. I used #4 sheet metal screws with 3mm flat washers to hold the knobs. 3mm machine screws could also work. Must not be stainless of course.
They should open in the best orientation for printing.
The magnets should take some pressure to snap in place. Put two magnets in each latch.