Hopes of a timely end to the Middle East conflict sparked a relief rally on the local bourse, but the optimism was limited, capping gains by the close.