First, you pray a lot.
Next you decide if the job is worth the aggravation that your boss is causing. I have work for such people in the newspaper and PR business. Grouchy and ill-tempered can really take on many forms.
I had a job where the boss told me early on that he did not want to hear what had been done in the past. I had been with the company for 20 years. He was new.
I responded by saying that I would tell him what we did, if it worked or did not work and offer my suggestions. At the end of the day, I would have completed the task he assigned the way he wanted it. I kept that promise, but I still lost my job--no reason was given, except that my position was being eliminated.
So depending on your age and financial situation you have to decide how much you can take and what you can do to avoid his ire. Otherwise you may want to move on. Unless there is some epiphany in his life, he is unlikely to change. I had several bosses over the years who believed they were always right.
I was fortunate to have three that were open to suggestion, new ideas and constructive criticism of what they were proposing. Those kind of bosses are hard to find, but if you do, hang on to that job as long as you can..