Heat the olive oil in a pan over medium heat. Add the the top bagel half, cut side facing up, to one side of the pan. To the other side, sprinkle ½ of the cheese in a circle the size of your bagel. Spoon ½ the pesto over the cheese. When the cheese melts, about 1 minute, flip the bagel, cut side facing down, onto the cheese. Crack 1 egg into the bagel hole. Season with salt and pepper. Cover and cook, until the whites are set, but the yolk is still runny, 6 to 8 minutes, or to your preference. Toast the remaining bagel half.