extract ip
This commit is contained in:
parent
05210d6c2d
commit
8029f92cd0
1 changed files with 5 additions and 1 deletions
|
@ -3,7 +3,11 @@
|
|||
uri:
|
||||
url: http://checkip.dyndns.org
|
||||
return_content: true
|
||||
register: node_external_ip
|
||||
register: checkip_url
|
||||
|
||||
- name: Extract IP from URL content
|
||||
set_fact:
|
||||
node_external_ip: checkip_url | regex_search('[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}')
|
||||
|
||||
- name: Set fact for mail server FQDN
|
||||
set_fact:
|
||||
|
|
Loading…
Reference in a new issue