كتاب صلاة المسافرين وقصرها
6  
The Book of Prayer - Travellers
(4)
Chapter: It is permissible to offer voluntary prayers atop one’s mount when travelling, no matter what direction it is facing
(4)
باب جَوَازِ صَلاَةِ النَّافِلَةِ عَلَى الدَّابَّةِ فِي السَّفَرِ حَيْثُ تَوَجَّهَتْ ‏‏
Sahih Muslim 700 i

Salim b. 'Abdullah reported on the authority of his father that the Messenger of Allah (may peace be. upon him) used to observe Nafl (supererogatory) prayer on his ride no matter in what direction it turned its face, and he observed Witr too on it, but did not observe obligatory prayer on it.

وَحَدَّثَنِي حَرْمَلَةُ بْنُ يَحْيَى، أَخْبَرَنَا ابْنُ وَهْبٍ، أَخْبَرَنِي يُونُسُ، عَنِ ابْنِ شِهَابٍ، عَنْ سَالِمِ بْنِ عَبْدِ اللَّهِ، عَنْ أَبِيهِ، قَالَ كَانَ رَسُولُ اللَّهِ صلى الله عليه وسلم يُسَبِّحُ عَلَى الرَّاحِلَةِ قِبَلَ أَىِّ وَجْهٍ تَوَجَّهَ وَيُوتِرُ عَلَيْهَا غَيْرَ أَنَّهُ لاَ يُصَلِّي عَلَيْهَا الْمَكْتُوبَةَ ‏.‏
Reference : Sahih Muslim 700i
In-book reference : Book 6, Hadith 49
USC-MSA web (English) reference : Book 4, Hadith 1505
  (deprecated numbering scheme)