Same reason the Germans and Japanese are now our allies. When you've soundly beaten your enemies, they tend to come around.
The Russians tried once to take Chechnya and failed so they went back a second time and leveled Grozny to rubble. And here we are.
And then some of your previous "allies" that helped you to beat them become your enemies, like Stalin and Mao.