Musnad Ahmad 724
It was narrated from ‘Ali that The Messenger of Allah (ﷺ) sent out an army and appointed a man in charge of them. He lit a fire and said:
Enter it. Some people wanted to enter it, but others said: This is what we wanted to flee from. That was mentioned to the Messenger of Allah (ﷺ) and he said to those who had wanted to enter it: “If you had entered it you would have remained in it until the Day of Resurrection.” He said some kind words to the others, then he said: `There is no obedience in that which involves disobedience towards Allah; obedience is only with regard to that which is right and proper.`
حَدَّثَنَا مُحَمَّدُ بْنُ جَعْفَرٍ، حَدَّثَنَا شُعْبَةُ، عَنْ زُبَيْدٍ الْإِيَامِيِّ، عَنْ سَعْدِ بْنِ عُبَيْدَةَ، عَنْ أَبِي عَبْدِ الرَّحْمَنِ، عَنْ عَلِيٍّ، رَضِيَ اللَّهُ عَنْهُ أَنَّ رَسُولَ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ بَعَثَ جَيْشًا وَأَمَّرَ عَلَيْهِمْ رَجُلًا فَأَوْقَدَ نَارًا فَقَالَ ادْخُلُوهَا فَأَرَادَ نَاسٌ أَنْ يَدْخُلُوهَا وَقَالَ آخَرُونَ إِنَّمَا فَرَرْنَا مِنْهَا فَذُكِرَ ذَلِكَ لِرَسُولِ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فَقَالَ لِلَّذِينَ أَرَادُوا أَنْ يَدْخُلُوهَا لَوْ دَخَلْتُمُوهَا لَمْ تَزَالُوا فِيهَا إِلَى يَوْمِ الْقِيَامَةِ وَقَالَ لِلْآخَرِينَ قَوْلًا حَسَنًا وَقَالَ لَا طَاعَةَ فِي مَعْصِيَةِ اللَّهِ إِنَّمَا الطَّاعَةُ فِي الْمَعْرُوفِ‏.‏