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

Expose portainer with Istio proxy #11649

Open
2 tasks done
EnricoBeltramo opened this issue Apr 21, 2024 · 0 comments
Open
2 tasks done

Expose portainer with Istio proxy #11649

EnricoBeltramo opened this issue Apr 21, 2024 · 0 comments
Labels

Comments

@EnricoBeltramo
Copy link

Before you start please confirm the following.

Problem Description

I want to expose the portaner interface (port 9000) behind an Istio proxy. Here the yaml that I used:
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
name: bookinfo-gateway-external
spec:
selector:
istio: aks-istio-ingressgateway-external
servers:

  • port:
    number: 80
    name: http
    protocol: HTTP
    hosts:
    • "*"

apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: bookinfo-vs-external
spec:
hosts:

  • "*"
    gateways:
  • bookinfo-gateway-external
    http:
  • match:
    • uri:
      prefix: "/portainer"
      rewrite:
      uri: "/"
      route:
    • destination:
      host: portainer.portainer.svc.cluster.local
      port:
      number: 9000

When I open the path, the portainer is found but say: Failure
Unable to retrieve server settings and status and the insterface is stopped. If I sue standard node port, it works correctly

Expected Behavior

Same behavious when opened by node port

Actual Behavior

Doesn't work behind Istio proxy

Steps to Reproduce

  • install portainer in AKS with Istio enabled
  • install Istio configuraion file:
    apiVersion: networking.istio.io/v1alpha3
    kind: Gateway
    metadata:
    name: bookinfo-gateway-external
    spec:
    selector:
    istio: aks-istio-ingressgateway-external
    servers:
    • port:
      number: 80
      name: http
      protocol: HTTP
      hosts:
      • "*"

apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: bookinfo-vs-external
spec:
hosts:

  • "*"
    gateways:
  • bookinfo-gateway-external
    http:
  • match:
    • uri:
      prefix: "/portainer"
      rewrite:
      uri: "/"
      route:
    • destination:
      host: portainer.portainer.svc.cluster.local
      port:
      number: 9000
  • open page at http:///portainer

Portainer logs or screenshots

Failure
Unable to retrieve server settings and status and the insterface is stopped. If I sue standard node port, it works correctly
image

Portainer version

2.20.1

Portainer Edition

Community Edition (CE)

Platform and Version

Kubernetes 1.27.9

OS and Architecture

Win11

Browser

Chrome

What command did you use to deploy Portainer?

Followed tutorial: 
https://docs.portainer.io/v/2.14/start/install/server/kubernetes/baremetal

Additional Information

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant