Zuhri reported,

I asked him whether the Prophet ﷺ had performed the prayer of fear. He said, Salim informed me that Abdullah bin Umar رضي الله عنهم said:I went on a military expedition with the Messenger of Allah ﷺ toward Najd. We faced the enemy and formed our ranks against them. The Messenger of Allah ﷺ stood to lead us in prayer. One group stood with him to pray, while another group faced the enemy. The Messenger of Allah ﷺ performed one bowing and two prostrations with those who were with him, then they withdrew to take the place of the group that had not yet prayed. That group then came forward, and the Messenger of Allah ﷺ performed one bowing and two prostrations with them, then he gave the closing salam. After that, each man stood and performed one bowing and two prostrations on his own.

Bukhari 942

Sahih

حدثنا أبو اليمان قال أخبرنا شعيب

عن الزهري قال

سألته هل صلى النبي ﷺ يعني صلاة الخوف قال أخبرني سالم أن عبد الله بن عمر رضي الله عنهما قال غزوت مع رسول الله ﷺ قبل نجد فوازينا العدو فصاففنا لهم فقام رسول الله ﷺ يصلي لنا فقامت طائفة معه تصلي وأقبلت طائفة على العدو وركع رسول الله ﷺ بمن معه وسجد سجدتين ثم انصرفوا مكان الطائفة التي لم تصل فجاءوا فركع رسول الله ﷺ بهم ركعة وسجد سجدتين ثم سلم فقام كل واحد منهم فركع لنفسه ركعة وسجد سجدتين

البخاري 942صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Prayer of fear
Chapter
Prayer of fear
Numbering
Darussalam 942
Bukhari 942