This.
EDIT: To expand on why I think Tasker is a better choice than a typical do not disturb app on the market is that I can have additional requirements before it has the phone go silent. Most apps work on a schedule (eg: silent between 11pm-6am), this is fine most of the time but what if I am out late one night? With Tasker I have it set to only go silent if 3 conditions are all met, it is between 11pm-6am, it is connected to my home wifi, and it is being charged (wireless charger on nightstand).