From 8b73a835c67a8a21302f65c9f471fef23e2b2a93 Mon Sep 17 00:00:00 2001 From: Emilien Mantel Date: Wed, 1 Sep 2021 11:02:12 +0200 Subject: [PATCH] Fix ngrok task to get hostname --- tests/includes/pre_common.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/includes/pre_common.yml b/tests/includes/pre_common.yml index 04c5003..7760cd3 100644 --- a/tests/includes/pre_common.yml +++ b/tests/includes/pre_common.yml @@ -13,8 +13,9 @@ when: ngrok.changed - name: SHELL | Get ngrok public address - shell: curl 'http://127.0.0.1:4040/api/tunnels/command_line' | jq '.public_url' | grep -oE '[[:alnum:]]+\.ngrok\.io' + shell: set -o pipefail && curl 'http://127.0.0.1:4040/api/tunnels/command_line' 2> /dev/null | jq -r '.public_url' | cut -d '/' -f 3 args: + executable: /bin/bash warn: false register: ngrok changed_when: false