What you should depends very much on what the button actually does. If it just connects to ground or the positive rail and doesn't carry a large current, and the Atmega328 is running on the same voltage as the rest of the circuit, you might be able to drive it directly with an IO pin. If it does source/sink a relatively large current, an external transistor might be preferable. If you need isolation or the switch is connected through a more complex arrangement (such as matrix arrangement to use more buttons than there are IO pins on the controlled system's microcontroller) you'll typically need an optocoupler or transistor. If you need isolation, an optocoupler or relay is needed.
In short, it all depends. Maybe you could tell us a little bit about your actual application?