Put on a brave face

To try to appear happy when faced with a bad situation.

My friend put on a brave face even though he had lost his job.