mirror of
https://github.com/chatmail/relay.git
synced 2026-06-11 06:01:07 +00:00
fix: Always deploy unbound.conf.d/chatmail.conf (#993)
This fixes issue with negative cache only disabled in ipv4-only mode. Follow up to #992 Signed-off-by: Jagoda Ślązak <jslazak@jslazak.com>
This commit is contained in:
committed by
GitHub
parent
e9e012234b
commit
d898f41064
@@ -171,16 +171,14 @@ class UnboundDeployer(Deployer):
|
|||||||
"unbound-anchor -a /var/lib/unbound/root.key || true",
|
"unbound-anchor -a /var/lib/unbound/root.key || true",
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
if self.config.disable_ipv6:
|
self.ensure_directory(
|
||||||
self.ensure_directory(
|
path="/etc/unbound/unbound.conf.d",
|
||||||
path="/etc/unbound/unbound.conf.d",
|
)
|
||||||
)
|
self.put_template(
|
||||||
self.put_template(
|
"unbound/unbound.conf.j2",
|
||||||
"unbound/unbound.conf.j2",
|
"/etc/unbound/unbound.conf.d/chatmail.conf",
|
||||||
"/etc/unbound/unbound.conf.d/chatmail.conf",
|
disable_ipv6=self.config.disable_ipv6,
|
||||||
)
|
)
|
||||||
else:
|
|
||||||
self.remove_file("/etc/unbound/unbound.conf.d/chatmail.conf")
|
|
||||||
|
|
||||||
def activate(self):
|
def activate(self):
|
||||||
server.shell(
|
server.shell(
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
# Managed by cmdeploy
|
# Managed by cmdeploy
|
||||||
server:
|
server:
|
||||||
|
{% if disable_ipv6 %}
|
||||||
interface: 127.0.0.1
|
interface: 127.0.0.1
|
||||||
do-ip6: no
|
do-ip6: no
|
||||||
|
{% endif %}
|
||||||
cache-max-negative-ttl: 0
|
cache-max-negative-ttl: 0
|
||||||
|
|||||||
Reference in New Issue
Block a user