I'm married, Torah observant, clean and sober 15 years in AA, and sexually sober for nearly four years. How did I/do I stay clean?
The first 90 days were definitely all about using what I had learned in AA, and inspiration from Chaim Kramer's book "Crossing the Narrow Bridge".
Since then, I take it "one day at a time," using my 12-steps experience, and Torah, Torah and more Torah (i.e. "the 11th step").
In my early days of AA, I used to study a lot of R' Twerski's books (i.e. A Day/A Week at a Time). Since then, I've studied a lot of Mussar books and a lot of R' Nachman, especially the works published by Chaim Kramer and his Breslov Research Institute, along with Lazer Brody's translations of Shalom Arush's books, and R Yitzchak Ginzberg's "The Mystery of Marriage". The more I've Kabbalistically understood masculine/feminine relationships and drives, and the more deeply I go into Torah and Mussar, the more I am able to 'grab the reins' whenever I start to go off course (as the Baal Shem Tov would say).
The more I know, the less I know, and I hope to figure out how best to be an active participant in recovery, stay clean, help others get and stay clean, keep getting cleaner, and keep improving my Shalom Bayis...