|
|
@ -52,8 +52,13 @@ |
|
|
|
|
|
|
|
- name: check number of nameservers |
|
|
|
fail: |
|
|
|
msg: "Too many nameservers" |
|
|
|
when: docker_dns_servers|length > 3 |
|
|
|
msg: "Too many nameservers. You can relax this check by set docker_dns_servers_strict=no and we will only use the first 3." |
|
|
|
when: docker_dns_servers|length > 3 and docker_dns_servers_strict|bool |
|
|
|
|
|
|
|
- name: rtrim number of nameservers to 3 |
|
|
|
set_fact: |
|
|
|
docker_dns_servers: "{{ docker_dns_servers[0:3] }}" |
|
|
|
when: docker_dns_servers|length > 3 and not docker_dns_servers_strict|bool |
|
|
|
|
|
|
|
- name: check number of search domains |
|
|
|
fail: |
|
|
|