Add option -L to curl, to retry on server error.