Websocket on another port

Hello.

Does anyone have an configuration example of a serperate websocket connection.
I have an external resource which is as follow

https://192.168.1.1:7272 -> webinterface
https://192.168.1.1.7273 -> websocket connection

I have the webinterface reverse proxied, imagine that it's proxied to https://test.domain.com
I can see that in the chrome developer tools, it's trying to build a websocket connection to wss://test.domain.com:7273/rdp?blabhlabh

Anyone has an idea if this is possible to also proxy this websocket through port 443 instead of needing two ports.

perhaps /rdp to port 7273 somehow, but i get hard linked to 7273

I wonder if there is a test application container anywhere that can be used for testing websocket setup.

I thought i could solve it with replacePathRegex middleware.
This is my dynamic_config.yml file

This doesn't work. i still get redirected to wss://pmp.docker.domain.com:7273

Any ideas?


http:
  routers:
    to-pmpwebinterface:
      rule: "Host(`pmp.docker.domain.com`)"
      tls:
        certResolver: acme
      middlewares:
      - pmp-websocketregex@file
      service: pmpwebinterface-service
    to-pmpwebsocket:
      rule: "Host(`pmpwebsocket.docker.domain.com`)"
      tls:
        certResolver: acme
      service: pmpwebsocket-service

  middlewares:
    pmp-websocketregex:
      replacePathRegex:
        regex: "^pmp.docker.domain.com:7273/(.*)"
        replacement: "pmpwebsocket.docker.domain.com/${1}"

  services:
    pmpwebinterface-service:
      loadBalancer:
        servers:
        - url: https://10.252.252.31:7272
    pmpwebsocket-service:
      loadBalancer:
        servers:
        - url: https://10.252.252.31:7273