Acceptance With Grace. The best_case scenario__and honestly, the most common reaction__is that your boss will accept your resignation with understanding and sincere congratulations. Your manager will be happy to see that you're advancing your career and moving on to something bigger and better.
However, I'm happy to help out however I can in the next two weeks." If you haven't landed a new gig yet or your new start date is negotiable, know your limits. If you're willing to stay an additional three weeks, for example, don't let your manager talk you into staying three more months.