Low dheas and high cortisol at night leads to extreme insomnia

I have very low dheas and high cortisol at night which I suspect is the cause of my chronic insomnia and excessive urination. Is there anything to lower cortisol other than ketoconazole? or something to heal the adrenal glands and get this back to normal?