From 5656e00e5bdbce5fad7e050f13a5c5c20a107371 Mon Sep 17 00:00:00 2001 From: djpbessems Date: Tue, 26 Apr 2022 13:31:43 +0200 Subject: [PATCH] Replace regexp group references w/ hardcoded strings --- playbook.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/playbook.yml b/playbook.yml index 2de63ee..deffe70 100644 --- a/playbook.yml +++ b/playbook.yml @@ -195,9 +195,8 @@ - name: Replace API url ansible.builtin.replace: path: "{{ kubeconfig.path }}" - regexp: '(server: https:\/\/)127\.0\.0\.1(:6443)$' - replace: >- - \1"{{ cluster.virtualip | ansible.utils.ipaddr('address') }}"\2 + regexp: 'server: https:\/\/127\.0\.0\.1:6443$' + replace: "server: https://{{ cluster.virtualip | ansible.utils.ipaddr('address') }}:6443" - ansible.builtin.slurp: src: "{{ kubeconfig.path }}" register: foo