From dc5c38331c6d0df0067e92bb9343d2060bdb4017 Mon Sep 17 00:00:00 2001 From: Logan V Date: Fri, 2 Mar 2018 11:36:33 +0000 Subject: [PATCH] Set timeouts on uri tasks uri task has a 30 second timeout by default, and in a greenfield or new host deploy these tasks are always expected to fail, so the timeout is expected to be met multiple times. We should set a small timeout on these tasks to fail quickly. Change-Id: I6748bbd894585d97cce235e854afbcf9d433d34d --- playbooks/common-tasks/set-pip-upstream-url.yml | 1 + playbooks/common-tasks/set-upper-constraints.yml | 2 ++ 2 files changed, 3 insertions(+) diff --git a/playbooks/common-tasks/set-pip-upstream-url.yml b/playbooks/common-tasks/set-pip-upstream-url.yml index 7fdc0353e2..dcb68d02e2 100644 --- a/playbooks/common-tasks/set-pip-upstream-url.yml +++ b/playbooks/common-tasks/set-pip-upstream-url.yml @@ -21,6 +21,7 @@ uri: url: "{{ pip_upstream_url }}" method: "HEAD" + timeout: 3 register: _repo_data_check failed_when: false when: pip_upstream_url != "https://bootstrap.pypa.io/get-pip.py" diff --git a/playbooks/common-tasks/set-upper-constraints.yml b/playbooks/common-tasks/set-upper-constraints.yml index 50cd96ae77..d97e167efc 100644 --- a/playbooks/common-tasks/set-upper-constraints.yml +++ b/playbooks/common-tasks/set-upper-constraints.yml @@ -22,6 +22,7 @@ uri: url: "{{ pip_install_upper_constraints }}" method: "HEAD" + timeout: 3 register: upper_constraints_check failed_when: false tags: @@ -31,6 +32,7 @@ uri: url: "{{ pip_default_index }}" method: "HEAD" + timeout: 3 register: pip_default_index_check failed_when: false tags: