-
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
blocky ansible role fails while waiting #4
Comments
blocky seems to be working
it correctly resolves google.com so im unsure why ansible is failing i can run the same dig command while ansible still seems to think its not working |
domain must be prefixed with '.', please read the comment in the readme and defaults file. |
it is i just removed it as i didnt want to leak my domain |
blocky logs, don't help much. |
i told ansible galaxy to install of main cat /opt/blocky/config.yaml
# Ansible managed
upstream:
default:
- 9.9.9.9
- 149.112.112.112
- 1.1.1.1
- 1.0.0.1
blocking:
blockTTL: 10s
blackLists:
ads:
- https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
- https://raw.githubusercontent.com/notracking/hosts-blocklists/master/hostnames.txt
- https://s3.amazonaws.com/lists.disconnect.me/simple_ad.txt
- https://blocklistproject.github.io/Lists/ads.txt
- https://raw.githubusercontent.com/hagezi/dns-blocklists/main/domains/pro.txt
malware:
- https://blocklistproject.github.io/Lists/malware.txt
- https://blocklistproject.github.io/Lists/ransomware.txt
- https://blocklistproject.github.io/Lists/scam.txt
- https://blocklistproject.github.io/Lists/phishing.txt
clientGroupsBlock:
default:
- ads
- malware
whiteLists:
ads:
- https://raw.githubusercontent.com/anudeepND/whitelist/master/domains/whitelist.txt
ports:
dns: 53
http: 4000
logLevel: info
caching:
minTime: 5m
maxTime: 60m
prefetching: true
customDNS:
customTTL: 60m
filterUnmappedTypes: true
rewrite:
mapping:
{}
conditional:
fallbackUpstream: false
mapping:
{}
prometheus:
enable: true
path: /metrics this is the config and it doesnt look as expected as the custom dns for hosts havent applied this is thee template file from my ansiblehome/roles direcotry # {{ ansible_managed }}
{% if blocky__hosts_dns_enabled -%}
# Added to blocky__custom_dns from inventory due to blocky__hosts_dns_enabled=true
{% for host in groups[blocky__hosts_dns_invenory_group] -%}
{% set fqdn = host + blocky__hosts_dns_domain %}
{% if (hostvars[host]["blocky__hosts_dns_ignore"] is undefined or not hostvars[host]["blocky__hosts_dns_ignore"])
and fqdn not in blocky__custom_dns
and hostvars[host][blocky__hosts_dns_host_ip_var] is defined
and host != "localhost" %}
{% set _ = blocky__custom_dns.update({ fqdn: hostvars[host][blocky__hosts_dns_host_ip_var] }) -%}
{% else -%}
# Skipping {{ host }}
{% endif -%}
{% endfor -%}
{% endif -%}
upstream:
{{ blocky__upstreams | to_nice_yaml(indent=2) | trim | indent(2) }}
blocking:
blockTTL: 10s
blackLists:
{{ blocky__blocking_blacklists | to_nice_yaml(indent=2) | trim | indent(4) }}
clientGroupsBlock:
{{ blocky__blocking_client_groups_block | to_nice_yaml(indent=2) | trim | indent(4) }}
whiteLists:
{{ blocky__blocking_whitelists | to_nice_yaml(indent=2) | trim | indent(4) }}
ports:
dns: {{ blocky__ports_dns | to_nice_yaml(indent=2) | trim | indent(2) }}
http: {{ blocky__ports_http | to_nice_yaml(indent=2) | trim | indent(2) }}
logLevel: {{ blocky__log_level | to_yaml }}
caching:
minTime: 5m
maxTime: 60m
prefetching: true
customDNS:
customTTL: 60m
filterUnmappedTypes: true
rewrite:
mapping:
{{ blocky__custom_dns | to_nice_yaml(indent=2) | trim | indent(4) }}
conditional:
fallbackUpstream: false
mapping:
{{ blocky__custom_domain | to_nice_yaml(indent=2) | trim | indent(4) }}
prometheus:
enable: true
path: /metrics |
Thanks, so did you add a |
ahhh!! its |
I've updated the config to add the second underscore |
custom dns works and i can dig it to get the correct result however for some reason the playbook still fails at https://github.com/ngine-io/ansible-role-blocky-dns/blob/d257d6e0fffd61ac9f95ac1322a384df55d9ef06/tasks/main.yml#L96C1-L99C13 |
Hi @Dialgatrainer02 I can not reproduce. Could you share the value of |
It is the default variable the only specified card are use host DNS and the host DNS domain. My code is at https://github.com/Dialgatrainer02/home-lab/tree/main/playbooks/dns.yml |
I also use lxc on proxmox: can you confirm, that in your blocky lxc:
|
When I get home I'll.be able to I'll.update you then |
I forgot I destroyed my home lab yesterday so I rebuilt it ran the playbook and it's working now?? |
the ansible error while running the role
this playbook snippet including my vars
journalctl output from blocky
The text was updated successfully, but these errors were encountered: