Commit f3cd951a authored by nanahira's avatar nanahira

skip username on ip addr

parent ad09f60e
Pipeline #15726 failed with stage
in 17 minutes
......@@ -16,14 +16,14 @@
become: true
hostname:
name: "{{ inventory_hostname }}"
when: inventory_hostname_short != '10' and inventory_hostname_short != '172' and inventory_hostname_short != '192' and not testing
when: inventory_hostname_short is not regex("^[0-9]+$") and not testing
- name: hostname hosts
become: true
blockinfile:
path: /etc/hosts
marker: '# {mark} MyCard Init block'
block: "{{ ansible_default_ipv4.address }} {{ inventory_hostname }} {{ inventory_hostname_short }}"
when: inventory_hostname_short != '10' and inventory_hostname_short != '172' and inventory_hostname_short != '192' and not testing
when: inventory_hostname_short is not regex("^[0-9]+$") and not testing
- name: clean aliyun
become: true
shell: |
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment