The best way to keep peace i think would be to ally everyone in the very beginning and try to start off huge alliance chains which would make all of the ai afraid to attack since one declaration of war may start off a huge chain of wars due to alliances. That faction with only one city left wont look to vulnerable if it has 5 strong allies ready to defend it