It's a cold war tale.  Nigerian Prime Minister [Abubakar Tarawa Balewa][1] 1960-1966 was pro-western.  When he was overthrown in a military coup and murdered January 15, 1966, it sparked a counter coup, and the [Nigerian Civil War][2] (July 6, 1967 – January 15, 1970).  During the Civil War the Soviets were a major arms supplier to the government, beginning the relationship which would turn into political support in the '70s.

In the 1970s Nigeria's relationship with the west began to lapse.  During this same time Nigeria found itself on the same side of several issues as the Soviet Union.  Nigeria was very critical of the white regimes in southern Africa, South African and Rhodesia.  The Soviet Union was supporting nationalist movements in both countries and this put them on the same side of these issues.  Nigeria sided with the Soviet Union throughout the '70s on such issues as action against apartheid, recognition of the MPLA in Angola, and immediate independence for Namibia.

All this interaction between Nigeria and the Soviet Union made the west pretty concerned that Nigeria was becoming a Soviet satellite state.  The Soviet Invasion of Afghanistan was a reordering episode.  Nigeria became a vocal critic of the Soviet invasion.  Distance was placed between Nigeria and the Soviet Union and a rapprochement with the west ensued.


**Sources:**

- **[Abubakar Tafawa Balewa][1]**
- **[Nigerian Civil War][2]**
- **[No Easy Row for a Russian Hoe: Ideology and Pragmatism in Nigerian-Soviet][3]**


[1]:https://en.wikipedia.org/wiki/Abubakar_Tafawa_Balewa
[2]:https://en.wikipedia.org/wiki/Nigerian_Civil_War
[3]:https://books.google.com/books?id=qnfyZ7rHbtoC&pg=PA154&dq=nigeria+soviet+invasion+of+afghanistan&hl=en&sa=X&ved=0ahUKEwip-pi_6u_cAhUEheAKHfcdCskQ6AEILDAB#v=onepage&q=nigeria%20soviet%20invasion%20of%20afghanistan&f=false