set curl timeout and retry