Start by caramelising the onions. Melt the butter in a large frying pan over a medium heat.
Add the onions and cook for 8–10 minutes until softened. Stir in the brown sugar and red wine vinegar, cooking for a further 5 minutes until caramelised and jammy. Set aside to cool slightly.
Preheat the oven to 220°C / 200°C Fan / 430°F.
Line a large baking sheet with non-stick baking paper.
Roll out the puff pastry sheets a little to enlarge them. Cut one circle about 23cm in diameter (for the base) and a second slightly larger circle about 26cm (for the lid).
Place the smaller pastry circle on the prepared tray. Spread the caramelised onions evenly over the base.
Sit the Camembert in the centre. Arrange the ham around the cheese in a ring. In a small bowl, mix the sour cream with the Dijon mustard, then spoon it over the ham.
Scatter generously with the grated Gruyère.
Brush the edge of the pastry base with beaten egg. Lay the larger pastry circle over the filling, folding the edges and pressing down firmly around the edges to seal. Then crimp the edges with a fork.
Cut a small hole in the centre to allow steam to escape. Score decorative curved lines from the centre outwards. Brush all over with egg wash.
Bake for 20–25 minutes, or until the pastry is puffed, golden, and crisp, and the filling is bubbling inside.
Let the pithivier rest for 5 minutes before slicing. Serve warm with a simple green salad.
The video below will help with this recipe.