B
B
bro-dev2019-11-03 04:41:20
Node.js
bro-dev, 2019-11-03 04:41:20

How to set up an ingress or node so that the express webserver does not know which way it is being proxied?

spoiler
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: example-ingress
  annotations:
    ingress.kubernetes.io/rewrite-target: /
spec:
  rules:
  - http:
      paths:
        - path: /mywebapi
          backend:
            serviceName: mywebapi-service
            servicePort: 80

doesn't work like that
spoiler
app.get('/', (req, res) => res.send('ok'));

that's how it works
spoiler
app.get('/mywebapi', (req, res) => res.send('ok'));

How to set up an ingres or a node so that it does not know at all which way it is being proxied?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question