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

Importing gateway-proxy in ProxyTemplates manifest results in error #3935

Closed
marcoferrer opened this issue Feb 26, 2022 · 2 comments · Fixed by #3937
Closed

Importing gateway-proxy in ProxyTemplates manifest results in error #3935

marcoferrer opened this issue Feb 26, 2022 · 2 comments · Fixed by #3937
Labels
area/gateway Built-in Kuma gateway support kind/bug A bug triage/accepted The issue was reviewed and is complete enough to start working on it

Comments

@marcoferrer
Copy link
Contributor

What happened?

kuma versions

Client: Kuma 1.5.0
Server: Kuma 1.5.0

This documentation leads me to believe that when writing a ProxyTemplate for a new built in gateway I should import gateway-proxy

https://kuma.io/docs/dev/policies/proxy-template/#builtin-gateway-support

But doing so results in the following error message

The ProxyTemplate "edge-gateway" is invalid: spec.conf.imports[0]: profile not found. Available profiles: default-proxy

This can be reproduced by applying the following manifest

apiVersion: kuma.io/v1alpha1
kind: ProxyTemplate
mesh: default
metadata:
  name: edge-gateway
spec:
  selectors:
    - match:
        kuma.io/service: edge-gateway
  conf:
    imports:
      - gateway-proxy
    modifications:
      - cluster:
          operation: add
          value: |
            name: test-cluster
            connectTimeout: 5s
            type: STATIC
@marcoferrer marcoferrer added kind/bug A bug triage/pending This issue will be looked at on the next triage meeting labels Feb 26, 2022
@marcoferrer
Copy link
Contributor Author

It looks like the proxy template validator is initializing the available profiles map using a const that doesnt contain the new profile

for _, profile := range AvailableProfiles {

var AvailableProfiles = []string{ProfileDefaultProxy}

const ProfileGatewayProxy = "gateway-proxy"

@lahabana lahabana added triage/accepted The issue was reviewed and is complete enough to start working on it area/gateway Built-in Kuma gateway support and removed triage/pending This issue will be looked at on the next triage meeting labels Feb 28, 2022
@github-actions github-actions bot added the triage/stale Inactive for some time. It will be triaged again label Mar 31, 2022
@github-actions
Copy link
Contributor

This issue was inactive for 30 days it will be reviewed in the next triage meeting and might be closed.
If you think this issue is still relevant please comment on it promptly or attend the next triage meeting.

@michaelbeaumont michaelbeaumont removed the triage/stale Inactive for some time. It will be triaged again label Mar 31, 2022
lahabana pushed a commit that referenced this issue Apr 1, 2022
Fix #3935

Signed-off-by: marco.ferrer <[email protected]>
Co-authored-by: Mike Beaumont <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/gateway Built-in Kuma gateway support kind/bug A bug triage/accepted The issue was reviewed and is complete enough to start working on it
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants