I'm building something made of aluminium that has mains electronics in it and DC

Also Steppers

It is a CNC machine technically just a very different one

Can I just connect the frame to gnd from the mains? to ground the frame and cladding

And can I connect a metal box to gnd and put my vfd in it for a CNC 3 axis?

Thanks