Well - the USSR and Cold War mentality helped with that one. Actually it was the Russian commander on site who initiated actually arming the nuclear war heads contrary to orders & policy from Moscow. All it then needed was to push the last button.

Ultimately Kennedy stone walled the risk and Moscow elected to pull back - ending with Kruchev's dismissal by the politbureau for his looser gamesmanship.