After the Russian Revolution, in which the Bolsheviks took over the old Russian Empire in 1918, they faced enormous odds against the German Empire and eventually negotiated terms to pull out of World War I. They then went to war against both domestic and international enemies in the bitter civil war. Tsarist Russia was reorganized as the Soviet Union in 1922 with Vladimir Lenin in charge. At first, it was treated as an unrecognized Pariah state because of its repudiating the tsarist debts and threats to destroy capitalism at home and around the world. By 1922, Moscow had repudiated the goal of world revolution, and sought diplomatic recognition and friendly trade relations with the capitalist world, starting with Britain and Germany. Finally in 1933 the United States gave recognition. Trade and technical help from Germany and the United States arrived in the late 1920s. After Lenin died in 1924, Joseph Stalin, seized power and in few years destroyed his enemies and became the dictator. He transformed the country in the 1930s into an industrial and military power. After the appeasement policy of Britain and France (which Stalin called "pro-fascist"), the Soviet Union shifted from a strategy of antifascist collective security to one of national security. By signing a Non-Aggression Pact with Germany in 1939 Moscow became friends with Berlin, gained most of the previous Tsarist controlled regions, and expanded trade. Stalin refused to believe repeated warnings that Hitler planned to invade and was caught by surprise in June 1941 when Nazi Germany invaded the Soviet Union and reached the outskirts of Leningrad and Moscow. However, the Soviet Union proved strong enough to defeat Nazi Germany, with help from its key allies.