'Goldeneye' was a British intelligence undertaking to monitor events in Spain after the end of Spanish Civil War (1939/45).
The object of the operation, devised by Lieutenant Commander Ian Fleming of the British naval intelligence branch, was to ensure that the UK would still be able to communicate with Gibraltar in the event Spain joined the Axis powers. The plan also incorporated elements for the defence of Gibraltar had the Germans invaded through Spain.
Ultimately General Francisco Franco y Bahamonde, the dictator of Spain, declined to join the Axis powers, Adolf Hitler having refused to give Gibraltar and French North Africa to Spain after these had been seized.