Hazrat Shaikh Moulana Muhammad Zakariyya (rahmatullahi ‘alaih) once mentioned:
My beloved friends! When you have a worldly need then you should adopt the halaal means to the point of necessity to fulfill the need. However, when adopting the means, you should keep your focus towards Allah Ta‘ala and remember that it is He alone who provides, not the means. I am not saying that the means should not be adopted. Rather, the means should not be made the purpose and goal in one’s life (i.e. one should not make compromises in one’s deen on account of one’s profession, means of livelihood, etc).
(Suhbat Baa Awliyaa pg. 188)