ngrok / kubernetes-ingress-controller

The official ngrok Ingress Controller for Kubernetes
https://ngrok.com
MIT License
183 stars 20 forks source link

Example ingress yaml should lowercase domain #325

Closed russorat closed 5 months ago

russorat commented 7 months ago

Kubernetes Version

civo kubernetes

Helm Chart Version

0.12.1

Helm Chart configuration

default config

What happened

after installing, i was greeted with the message:

Enabling ngrok ingress controller in {ngrok-ingress-controller} namespace
Hang tight while we grab the latest from your chart repositories...
...Successfully got an update from the "ngrok" chart repository
Update Complete. ⎈Happy Helming!⎈
Release "ngrok-ingress-controller" does not exist. Installing it now.
NAME: ngrok-ingress-controller
LAST DEPLOYED: Mon Dec  4 11:54:42 2023
NAMESPACE: ngrok-ingress-controller
STATUS: deployed
REVISION: 1
TEST SUITE: None
NOTES:
================================================================================
The ngrok Ingress controller has been deployed as a Deployment type to your
cluster.

If you haven't yet, create some Ingress resources in your cluster and they will
apiVersion: networking.k8s.io/v1
be automatically configured on the internet using ngrok.

One example, taken from your cluster, is the Service:
   "metrics-server"

You can make this accessible via ngrok with the following manifest:
--------------------------------------------------------------------------------
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: metrics-server
  namespace: kube-system
spec:
  ingressClassName: ngrok
  rules:
  - host: metrics-server-c0M3fw6S.ngrok.app
    http:
      paths:
      - path: /
        pathType: Prefix
        backend:
          service:
            name: metrics-server
            port:
              number: 443
--------------------------------------------------------------------------------
Applying this manifest will make the service "metrics-server"
available on the public internet at "https://metrics-server-c0M3fw6S.ngrok.app/".

Once done, view your edges in the Dashboard https://dashboard.ngrok.com/cloud-edge/edges
Find the tunnels running in your cluster here https://dashboard.ngrok.com/tunnels/agents

If you have any questions or feedback, please join us in https://ngrok.com/slack and let us know!

When i tried to apply that ingress yaml, i received the error message:

kubectl apply -f ingress.yaml                                     3.0.0 ⎈ my-cluster
The Ingress "metrics-server" is invalid: spec.rules[0].host: Invalid value: "metrics-server-c0M3fw6S.ngrok.app": a lowercase RFC 1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character (e.g. 'example.com', regex used for validation is '[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*')

What you think should happen instead

the example we provide should have a lowercased hostname

How to reproduce

No response