Hello, and thanks for your question.
You are a very good and supportive mom to your son, and that is what he needs right now. Your son's dad is shocked, feels betrayed by you, and is embarrassed about his son's revelation; all natural reactions for himself, but not putting his son's feelings first, as we must do, as parents.
You were asked to keep an important confidence by your son, and you respected his wishes. Your son's dad doesn't understand that you cannot 'prevent' a person from being gay or 'turning' gay. It would be a good idea to suggest to your son's dad, that he reads up on a teen revealing to his parents that he's gay, and how the parents can be supportive to their son.
What matters most, is that your son knows that you love him, accept who he is, and the sexual orientation he chose, and that you will love him unconditionally, no matter what. It's important that he knows how you feel about this situation, and tell him that his father loves him too, but he reacted badly to this 'sudden' news, and you will try your best to help him understand what your son is going through at this time.
If your son lives with you and doesn't see his dad in person, that often, right now, that's a good thing, if his father is causing him to feel badly about himself. He has done nothing wrong and it's important that you keep reminding him of this. You don't want him to get depressed about this situation and feel there's nothing he can do about it. In fact, it might be a good idea to suggest he sees an experienced counselor/therapist, who is experienced in working with gay male teens. It will help him to talk about his feelings that he may not feel 'that' comfortable discussing with you, his mom. Of course assure him he can discuss *anything* with you, and you will not judge him, but give your best opinion/thoughts on the subject. At the same time, he might feel more comfortable discussing his situation with a person who is a 'stranger', and who is a licensed and experienced counselor in these matters.
I wish you, your son and his dad, all the best.