Can I mount a light switch and power on the outside of a wall?
I don't believe there's any code stating you need to put electrical wiring, outlets, switches inside the wall as long as they are of the correct type. Use conduit for both safety and asthetics.

It would violate codes to go the other way, and say run standard extension power cables inside the walls though.

Simple example:
How to