diff --git a/.github/workflows/integration-test-global.yaml b/.github/workflows/integration-test-global.yaml index ebd75a9e..4dbb4653 100644 --- a/.github/workflows/integration-test-global.yaml +++ b/.github/workflows/integration-test-global.yaml @@ -3,6 +3,7 @@ name: Global integration tests on: pull_request: paths: + - 'tests/**' - 'bind-operator/src/**' - 'bind-operator/tests/**' - 'bind-operator/requirements.txt' @@ -15,6 +16,10 @@ on: - 'dns-integrator-operator/tests/**' - 'dns-integrator-operator/requirements.txt' - 'dns-integrator-operator/charmcraft.yaml' + - 'dns-secondary-operator/src/**' + - 'dns-secondary-operator/tests/**' + - 'dns-secondary-operator/requirements.txt' + - 'dns-secondary-operator/charmcraft.yaml' - '.github/workflows/integration-test-global.yaml' push: branches: @@ -23,7 +28,7 @@ on: jobs: integration-test: name: Integration tests - timeout-minutes: 60 + timeout-minutes: 120 runs-on: ubuntu-24.04 steps: - name: Disable snap autorefresh diff --git a/dns-resolver-operator/src/bind.py b/dns-resolver-operator/src/bind.py index 52f54e61..fb54acc1 100644 --- a/dns-resolver-operator/src/bind.py +++ b/dns-resolver-operator/src/bind.py @@ -196,7 +196,7 @@ def _generate_named_conf_options(self) -> str: """ content: str = "" content += templates.NAMED_CONF_OPTIONS_TEMPLATE.format( - allow_query="0.0.0.0/0", + allow_query="any", ) return content diff --git a/dns-secondary-operator/src/bind.py b/dns-secondary-operator/src/bind.py index 1f24258c..519ba6bb 100644 --- a/dns-secondary-operator/src/bind.py +++ b/dns-secondary-operator/src/bind.py @@ -55,7 +55,7 @@ def write_config_options(self, enable_tls: bool = False) -> None: Args: enable_tls: enable TLS configuration. Defaults to False. """ - allow_query = "0.0.0.0/0" + allow_query = "any" content: str = "" options = templates.NAMED_CONF_OPTIONS_TEMPLATE.format(allow_query=allow_query) if enable_tls: diff --git a/tests/test_charms.py b/tests/test_charms.py index 96ae88fe..e0ec483c 100644 --- a/tests/test_charms.py +++ b/tests/test_charms.py @@ -200,8 +200,25 @@ async def test_active( }, ) - # Waiting for 2mn as this is the maximum time for bind's config to update and propagate - time.sleep(120) + juju.wait( + lambda status: ( + jubilant.all_active( + status, + bind_name, + dns_resolver_name, + dns_secondary_name, + ) + and jubilant.all_agents_idle( + status, + bind_name, + dns_resolver_name, + dns_secondary_name, + dns_integrator_name, + ) + ), + error=jubilant.any_error, + successes=10, + ) # Check that bind and dns-resolver respond correctly for ip in [bind_ip, dns_resolver_ip, dns_secondary_ip]: