Abdullah bin Umar reported,

The Messenger of Allah ﷺ used to pray on his mount during travel, facing whichever direction it took him.Malik said, Abdullah bin Dinar reported that Ibn Umar used to do the same.

Nasai 493

Sahih

أخبرنا قتيبة بن سعيد عن مالك عن عبد الله بن دينار

عن ابن عمر قال

كان رسول الله ﷺ يصلي على راحلته في السفر حيثما توجهت به قال مالك قال عبد الله بن دينار وكان ابن عمر يفعل ذلك

النسائي 493صحيح
Contents
Reference
Commentary
Ayat
Collection
Sunan Nasai Sughra
Book
Prayer
Chapter
Situation in which facing other than the qibla is permissible
Numbering
Darussalam 493
Nasai 493