From b15c156bea410efa01db8aa1410b590e877d08ad Mon Sep 17 00:00:00 2001 From: "Jose I. Paris" Date: Tue, 17 Dec 2024 23:57:23 +0100 Subject: [PATCH] fix(policies): ignore http 405 as well as 404 (#1672) Signed-off-by: Jose I. Paris --- app/controlplane/pkg/policies/policyprovider.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controlplane/pkg/policies/policyprovider.go b/app/controlplane/pkg/policies/policyprovider.go index 0603dd077..9938b6328 100644 --- a/app/controlplane/pkg/policies/policyprovider.go +++ b/app/controlplane/pkg/policies/policyprovider.go @@ -138,7 +138,7 @@ func (p *PolicyProvider) ValidateAttachment(att *schemaapi.PolicyAttachment, tok } if resp.StatusCode != http.StatusOK { - if resp.StatusCode == http.StatusNotFound { + if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusMethodNotAllowed { // Ignore endpoint not found as it might not be implemented by the provider return nil }