The US president’s warning comes after Iran struck near an Israeli nuclear facility and Tehran says one of its nuclear sites was targeted.