Pour the oil into a large, deep skillet and place over medium-high heat. Add the onion, garlic and chili and cook about 5 minutes, or until the onion is softened but not browned.
Stir in the spices, harissa paste and 1 1/2 teaspoon salt and cook 1 minute. Add the tomatoes and beans, stir, and bring to a simmer.
Cook about 15 minutes, stirring occasionally, until the sauce is the consistency of thick jam. Remove the pan from the heat. Use the back of a spoon (a ladle works well) to make 6 wells in the sauce. Crack an egg into each one.
Put the pan back over medium heat and cover. Cook 4-6 minutes, just until the whites are set and opaque and the yolks are still runny. The eggs will continue to cook for a few minutes after you take the pan off the stove, so keep that in mind and cook to your preference.
Sprinkle the feta cheese and cilantro over the eggs and serve warm with toasted bread or pita.
To make ahead: You can make the sauce and refrigerate up to 5 days ahead. Reheat gently in a skillet until simmering, then add the eggs and cook according to the directions.