Preheat oven to 200 degrees C. Flour bottom and sides of deep baking dish. Line bottom and up the sides with flaky pastry.
Get slices of bacon and line the bottom. Put a layer of peas on top of bacon. Then break eggs on top of the bacon. If you like onion sprinkle chopped onion, more peas and then top with more bacon. Sprinkle with salt and pepper.
Place flaky pastry on top. Prick several times. Roll or crimp edges so the egg doesn't escape. Brush with a little milk. Bake in preheated oven for about 40 minutes. Eat hot or cold.
Use as many eggs as you like, the more you use the deeper your pie will be.