Skip to content
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

Using on invalid targetRef leads to a failure in the validation of the targetRef not in the validation of kind #11735

Open
lahabana opened this issue Oct 9, 2024 · 0 comments
Labels
kind/bug A bug triage/pending This issue will be looked at on the next triage meeting
Milestone

Comments

@lahabana
Copy link
Contributor

lahabana commented Oct 9, 2024

What happened?

apiVersion: kuma.io/v1alpha1
kind: MeshExternalService
metadata:
  name: datadog-trace-on-km
spec:
  endpoints:
  - address: trace-svc.datadog-agent.svc.cluster.local
    port: 8126
  match:
    port: 8126
    protocol: http
    type: HostnameGenerator
---
apiVersion: kuma.io/v1alpha1
kind: MeshTrafficPermission
metadata:
  name:  datadog-trace-test
spec:
  targetRef:
    kind: MeshExternalService
    labels:
      app: datadog-trace
  from:
    - targetRef:
        kind: Mesh
      default:
        action: Allow

Returns:

The MeshTrafficPermission "datadog-trace-test" is invalid: spec.targetRef.name: must be set with kind MeshExternalService

The error should just be that kind: MES in not supported.

I don't know if it's an error specific to MTP or more general.

@lahabana lahabana added triage/pending This issue will be looked at on the next triage meeting kind/bug A bug labels Oct 9, 2024
@lahabana lahabana added this to the 2.10.x milestone Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug A bug triage/pending This issue will be looked at on the next triage meeting
Projects
None yet
Development

No branches or pull requests

1 participant