move curl inside loop because unix said so