And what brings this about? Hitler's demise is the only thing that could possibly do the trick.
Germany faced virtual stalemate on the West. There was little they could do against Britain in a reasonably short or medium term. It would mean they satisfy with fighting war on periphery, without the prospect of quick, decisive victory in a short war, a strategy invented and preferred by Germans since XIX century. In order to do this they would have to place full trust in the Soviets and come up with a way of paying for their deliveries of vital war materials for the duration of hostilities in the West. Which in absolutely the best case could take up to two years, but most likely more.
If they pay the Soviets with machine tools and weapons as it was being done, along with looking the other way on occasional territorial grab by Stalin, Germans will not be in position to attack the USSR ever. Most likely Stalin chooses to strangle them eventually and extract more and more favors from Germany. And Nazis will not stand it.
Quite aside, and as others pointed out already, the entire point of the war was to attack the USSR.