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

Failed to query provider "https://dex.example.org/": 400 Bad Request: Client sent an HTTP request to an HTTPS server. #165

Open
oz123 opened this issue Mar 23, 2021 · 0 comments

Comments

@oz123
Copy link

oz123 commented Mar 23, 2021

Not sure if this is a real issue, this happens when I configure Dex to use TLS and also configure an NGINX ingress with TLS
In dex.yaml

ingress:
  enabled: true
  annotations:
    kubernetes.io/ingress.class: "nginx"
    cert-manager.io/cluster-issuer: "letsencrypt-production"
  tls:
  - secretName: dex-tls
    hosts:
      - https://dex.example.org/
  hosts:
  - https://dex.example.org/
...
web:
    https: 0.0.0.0:5556
    tlsCert: /etc/dex/tls/tls.crt
    tlsKey: /etc/dex/tls/tls.key

If I enable TLS and remove TLS from the ingress e.g:

  ingress:
  enabled: true
  annotations:
    kubernetes.io/ingress.class: "nginx"
    cert-manager.io/cluster-issuer: "letsencrypt-production"
  #tls:
  # - secretName: dex-tls
  #   hosts:
  #     - dex.example.org
  hosts:
  - dex.example.org

I get the following error:

k logs -n dex dex-k8s-authenticator-1616507655-7859889667-q4wkf 
2021/03/23 14:30:48 Using config file: /app/config.yaml
2021/03/23 14:30:48 Creating new provider https://dex.example.org/
2021/03/23 14:30:48 Failed to query provider "https://dex.example.org/": Get https://dex.example.org/.well-known/openid-configuration: remote error: tls: internal error

I had success with using lngress + Let's encrypt certificates for both dex and dex-k8s-authenitcator.

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

No branches or pull requests

1 participant