Muhammad Siad Barre is notable for switching sides in the Cold War.
After seizing power in a coup in 1969, he aligned Somalia with the Soviet Union, and by the mid-1970’s, the Soviets had naval bases there. However, when a Communist faction seized power in Ethiopia, Somalia’s archenemy in 1974, the Soviets started backing that regime. When Somalia and Ethiopia went to war in 1977, the Ethiopians beat off the Somali invasion thanks to massive Soviet military aid. Meanwhile, Somalia ditched the Soviets and aligned itself witht the West.