Israel and Hamas agree a ceasefire after the worst flare up in violence in Gaza since the war in 2014