Hi all.
I am trying to use regex_replace to capture the host name in a url. This is the code : {{ openerp_url | regex_replace(‘^(?:h.//)?(.)(?:(?::|/).*)$’, ‘\1’) }}. But, when the playbook is run, it is only giving \1 as the output. Checked with the latest ansible dev version as well. No luck. Even, the example given in the documentation {{ ‘ansible’ | regex_replace(‘^a.i(.)$’, ‘a\1’) }} gives a\1 as output.
Thanks,