Shittah Mekubetzes on Amud Aleph remarks that the Mishna often discusses people who vow against drinking wine because drunkenness brings sorrow and regret. He is paraphrasing a Gemara (Yoma 76b)
וְאַמַּאי קָרֵי לֵיהּ יַיִן, וְאַמַּאי קָרֵי לֵיהּ תִּירוֹשׁ? יַיִן — שֶׁמֵּבִיא יְלָלָה לְעוֹלָם. תִּירוֹשׁ — שֶׁכׇּל הַמִּתְגָּרֶה בּוֹ נַעֲשָׂה רָשׁ.
The Gemara asks: And if so, why does the Bible call it wine and why does it call it tirosh? The Gemara explains: “Wine” suggests that it brings lament to the world because drunkenness causes most sins. There is a phonetic resemblance between the yayin, wine, and ta’aniya va’aniya, sorrow and howling, which Rashi (on Job 2:5) explains as lament. “Tirosh” shows that those who indulge in it become poor [rash].
While this is certainly true of intoxication, like all ethical matters they are subject to circumstances and review. After all, Judaism does not forbid alcohol unlike other religions, and with 613 commandments, we cannot say the Torah is reluctant to prohibit.
In fact, Chovos Halevavos says the following about consumption of wine (Shaar Haperisha 5):
ואח״כ תתנהג בתענית אם יהיה גופך חזק אפי׳ יום א׳ בשבוע. וכל אשר תוכל להטביע נפשך שלא להרגיש על ענין המאכל והמשתה כדי ליסרה עשה ושים כוונתך בו לרפואה יותר מלמזון אבל משתך יהיה מים אלא אם תהיה כוונתך בשתית היין לתועלת גופך או להעביר דאגה מלבך כמ״ש (שם לא) תנו שכר לאובד ויין למרי נפש והזהר מהרבות ממנו ומהפליג בו ומחברת ב''א עליו כי הוא המדוה הגדול לתורה ולעולם וכבר ספר בו החכם מה שיש בו די באמרו (שם כ) לץ היין הומה שכר ואמר במאכל ובמשתה (שם כג) אל תהי בסובאי יין בזוללי בשר למו כי סובא וזולל יורש וגו',
Afterwards, practice fasting if your body is strong enough, even if this is only one day per week. Whatever you can do to train yourself to be indifferent to matters of eating and drinking, do so. Regard what you eat as a medicine (to heal your hunger) rather than as food. Your drinking should be only water, unless your intent in drinking wine is to benefit your body, or to remove distress from your heart, as written: "Give strong drink to he who is ready to perish and wine to the bitter soul" (Mishlei 31:6).Afterwards, practice fasting if your body is strong enough, even if this is only one day per week. Whatever you can do to train yourself to be indifferent to matters of eating and drinking, do so. Regard what you eat as a medicine (to heal your hunger) rather than as food. Your drinking should be only water, unless your intent in drinking wine is to benefit your body, or to remove distress from your heart, as written: "Give strong drink to he who is ready to perish and wine to the bitter soul" (Mishlei 31:6).
This is an expansion of a later statement from the Gemara Yoma (ibid)
לֹא זָכָה — נַעֲשָׂה רָשׁ. (וְהַיְינוּ דְּרָבָא דְּרָבָא) רָמֵי, כְּתִיב: ״יְשַׁמַּח״, וְקָרֵינַן יְשַׂמַּח. זָכָה — מְשַׂמְּחוֹ, לֹא זָכָה — מְשַׁמְּמוֹ. וְהַיְינוּ דְּאָמַר רָבָא: חַמְרָא וְרֵיחָנֵי — פַּקְחֻין.
Rav Kahana raised a contradiction: It is written as tirash but we read it tirosh. This should be understood as follows: If one merits and drinks appropriately, he is made a head [rosh]; if one does not merit and does not drink appropriately, he is made poor [rash]. The Gemara comments: This is the same as what Rava said, as Rava raised a contradiction: It is written: “And wine that makes glad [yishamaḥ] the heart of man” (Psalms 104:15) with a shin, but we read it yisamaḥ with a sin. This teaches: If one merits, wine makes him happy [same’aḥ]; if one does not merit, it makes him confounded [shamem]. This is the same as what Rava said: Wine and good scents make me wise, meaning that wine benefits one who deserves it.
Though Chovos Halevavos warns against excessive and even moderate consumption of alcohol, he noted that it can have a medicinal purpose to alleviate anxiety. For those who resist taking medication for anxiety or depression because somehow it feels like cheating or failing to “man up” and deal with your problems, this Chovos Halevavos would seem to support taking medication to alleviate anxiety. He even recommends wine, while cautioning against its negative effects. It therefore is logical to say he would endorse medications that are are not narcotic nor intoxicating such as SSRI’s. Anyone who has studied the Chovos Halevavos will notice he is not one to allow for rationalization or taking the easy road, so this statement is even more significant coming from him.