Workaround RKE binary download issue 63/117363/1
authorBartek Grzybowski <b.grzybowski@partner.samsung.com>
Tue, 2 Feb 2021 13:49:17 +0000 (14:49 +0100)
committerBartek Grzybowski <b.grzybowski@partner.samsung.com>
Tue, 2 Feb 2021 13:49:17 +0000 (14:49 +0100)
RKE binary download was _randomly_ failing (in ONAP's CI minion only)
with a message '_ssl.c:602: The handshake operation timed out' without
any easily trackable reason. Hence switching from get_url ansible module
to direct 'curl' command invocation which allows better timeout handling
at connection phase.

Change-Id: I70d734dfd8c04ba8b092350933c97c56f74d6208
Issue-ID: OOM-2665
Signed-off-by: Bartek Grzybowski <b.grzybowski@partner.samsung.com>
ansible/test/roles/prepare-rke/tasks/infra.yml

index 6e7bcb9..8aa93ca 100644 (file)
@@ -5,6 +5,10 @@
     state: directory
 
 - name: "Install rke-{{ rke_version }}"
-  get_url:
-    url: "https://github.com/rancher/rke/releases/download/v{{ rke_version }}/rke_linux-amd64"
-    dest: "{{ app_data_path }}/downloads/rke_linux-amd64"
+  command: "curl --connect-timeout 10 -L https://github.com/rancher/rke/releases/download/v{{ rke_version }}/rke_linux-amd64 -o {{ app_data_path }}/downloads/rke_linux-amd64"
+  register: result
+  retries: 10
+  delay: 1
+  until: not result.failed
+  args:
+    warn: false