The Prussian-led North German Confederation under Bismarck and the South German States united to fight the French. Bismarck knew that the South would see France as the aggressor in the war, which they did, and they would side with Prussia in the Franco-Prussian War. Together they formed the first German Empire, and their military outclassed any French resistance.
The success of the new German united armies served as a permanent unifier of the different German states, over which Bismarck would become the Emperor. France remained their enemy, having lost territory in the war, and the common enemy helped create conditions where Germany would stay united.