webhookrelay / webhookrelay-operator

A lightweight tunnelling operator to receive & process webhooks/API requests without public IP or load balancers in your Kubernetes cluster
https://webhookrelay.com
Mozilla Public License 2.0
19 stars 1 forks source link

Feature Request: Support Websockets #19

Open rhys-evans opened 2 years ago

rhys-evans commented 2 years ago

Support the WEBSOCKET_TRANSPORT=true environment variable, documented here https://docs.webhookrelay.com/installation-options/containerized/docker

This is to cover use cases where tcp/8080 (default GRPC port) is not allowed out of the client network

This lack of functionality is currently stopping us from deploying the solution.

rhys-evans commented 2 years ago

Hi, Thanks for this https://github.com/webhookrelay/webhookrelay-operator/pull/20 we will be busy testing it over the course of this week.

I do have a qq What was the logic around the GRPC being on non standard http ports ? IE not tcp/80, tcp/443

Sorry just curious.

SKY-Mark-Rhoades-Brown commented 2 years ago

Hi @rusenask, I would like to thank you for the very quick response to this. It does seem to have resolved the issue for us.

2022-11-10 09:49:05.496 INFO    using websocket based transport...
3
2022-11-10 09:49:05.496 INFO    authenticating to 'wss://my.webhookrelay.com:443/v1/socket'...
2
2022-11-10 09:49:05.496 INFO    websocket reader process started...
1
2022-11-10 09:49:05.518 INFO    subscribing to buckets: [my-webhooks]

I have a couple of points...

rusenask commented 2 years ago

Hi, Thanks for this #20 we will be busy testing it over the course of this week.

I do have a qq What was the logic around the GRPC being on non standard http ports ? IE not tcp/80, tcp/443

Sorry just curious.

Mostly due to historical reasons, however we will probably switch to 443 for grpc too as the support has been available for quite some time on GCP GKE ingress and I haven't seen any issues with it.

rusenask commented 2 years ago

Hi @rusenask, I would like to thank you for the very quick response to this. It does seem to have resolved the issue for us.

2022-11-10 09:49:05.496   INFO    using websocket based transport...
3
2022-11-10 09:49:05.496   INFO    authenticating to 'wss://my.webhookrelay.com:443/v1/socket'...
2
2022-11-10 09:49:05.496   INFO    websocket reader process started...
1
2022-11-10 09:49:05.518   INFO    subscribing to buckets: [my-webhooks]

I have a couple of points...

  • The image in dockerhub is 'tatest', but the chart's values.yaml tags it at 0.5.1
  • The Chart.yaml version numbers

Hi, the new chart has not been released yet. I will try to get the multiarch build on gh actions working later today :)

SKY-Mark-Rhoades-Brown commented 2 years ago

OK. If you are continuing to look, I have a trivial issue, which I can raise another ticket for it you would like....

apiVersion: forward.webhookrelay.com/v1
kind: WebhookRelayForward
metadata:
  name: example-forward
spec:
  resources:
    limits:
      cpu: 100m
      memory: 4Gi
    requests:
      cpu: 100m
      memory: 0.5Gi

Resource requests and limits are expressed in the CRD, but never make it into the deployment and pod. I could raise another request if you would like for this.

rusenask commented 2 years ago

should be fixed both in the newest chart + image

SKY-Mark-Rhoades-Brown commented 2 years ago

Hi. I have rolled out this new version, it looks improved. I can see that the resource limits have been applied to the forwarder deployment.

Everything looks great.