From 7bffdbc0ebf697b94a5db2bd92e1df5791e20204 Mon Sep 17 00:00:00 2001 From: omnom62 Date: Sun, 20 Sep 2026 10:46:52 +1000 Subject: https: T8989: auth_methods AI comments fixed --- docs/vyos.rest.vyos_httpapi.rst | 5 +++++ plugins/httpapi/vyos.py | 8 +++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/docs/vyos.rest.vyos_httpapi.rst b/docs/vyos.rest.vyos_httpapi.rst index 2c2d490..2489edc 100644 --- a/docs/vyos.rest.vyos_httpapi.rst +++ b/docs/vyos.rest.vyos_httpapi.rst @@ -166,6 +166,11 @@ Examples .. code-block:: yaml + # NOTE: ansible_httpapi_validate_certs: false below is shown for lab/testing + # convenience with self-signed certificates only. In production, use a + # properly signed certificate and set ansible_httpapi_validate_certs: true + # (the default) -- or omit the option entirely. + # inventory.yml - form-field API key (default, backward-compatible) all: hosts: diff --git a/plugins/httpapi/vyos.py b/plugins/httpapi/vyos.py index 7611b31..b21ca7d 100644 --- a/plugins/httpapi/vyos.py +++ b/plugins/httpapi/vyos.py @@ -95,6 +95,11 @@ notes: """ EXAMPLES = r""" +# NOTE: ansible_httpapi_validate_certs: false below is shown for lab/testing +# convenience with self-signed certificates only. In production, use a +# properly signed certificate and set ansible_httpapi_validate_certs: true +# (the default) -- or omit the option entirely. + # inventory.yml - form-field API key (default, backward-compatible) all: hosts: @@ -329,7 +334,8 @@ class HttpApi(HttpApiBase): access_token = token_response.get("access_token") if not access_token: raise ConnectionError( - "OIDC token response missing a valid access_token: {0}".format(raw[:300]), + "OIDC token response missing a valid access_token " + "(response keys: {0}).".format(sorted(token_response.keys())), ) self._oidc_token = access_token -- cgit v1.2.3