Skip to content

Commit 8023c98

Browse files
committed
chore: Add go-generate tags to recreate the OpenAPI bindings
1 parent dced359 commit 8023c98

File tree

5 files changed

+11
-19
lines changed

5 files changed

+11
-19
lines changed

README.md

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -23,23 +23,9 @@ where TURN credentials are usually negotiated in JavaScript.
2323

2424
## Description
2525

26-
By providing a cloud-based relay service, STUNner ensures that WebRTC peers can establish a media connection via TURN even when one or both sides is incapable of a direct P2P connection. This is the case, for instance, when media servers are deployed in a Kubernetes cluster.
27-
28-
As a gateway service,
29-
STUNner opens external access to the Kubernetes cluster. STUNner implements a mechanism to control user access via long-term credentials that are provided as
30-
part of the TURN protocol. It is expected that these credentials will be kept secret; if the
31-
credentials are discovered, the TURN server could be used by unauthorized users or applications.
32-
However, in web applications, ensuring this secrecy is typically impossible.
33-
34-
To address this problem, the STUNner authentication service provides a REST API that can be used to retrieve TURN
35-
credentials to access STUNner. The service watches the running STUNner dataplane configuration(s)
36-
from Kubernetes and automatically generates TURN credentials that will match the current
37-
[authentication settings](https://github.com/l7mp/stunner/blob/main/doc/AUTH.md) for STUNner. The
38-
REST API also allows to easily filter the returned TURN URIs to a selected set of STUNner Gateways:
39-
it is possible to return all public TURN URIs per Kubernetes namespace, select a particular STUNner
40-
Gateways within a namespace, or specify exactly which STUNner Gateway listener (say, TCP or UDP)
41-
the returned credential should apply to. This allows to direct users to access the Kubernetes
42-
cluster via a specific STUNner listener.
26+
By providing a cloud-based relay service, STUNner ensures that WebRTC peers can establish a media connection via TURN even when one or both sides is incapable of a direct P2P connection. This is the case, for instance, when media servers are deployed in a Kubernetes cluster. As a gateway service, STUNner opens external access to the Kubernetes cluster. STUNner implements a mechanism to control user access via long-term credentials that are provided as part of the TURN protocol. It is expected that these credentials will be kept secret; if the credentials are discovered, the TURN server could be used by unauthorized users or applications. However, in web applications, ensuring this secrecy is typically impossible.
27+
28+
To address this problem, the STUNner authentication service provides a REST API that can be used to retrieve TURN credentials to access STUNner. The service watches the running STUNner dataplane configuration(s) from Kubernetes and automatically generates TURN credentials that will match the current [authentication settings](https://github.com/l7mp/stunner/blob/main/doc/AUTH.md) for STUNner. The REST API also allows to easily filter the returned TURN URIs to a selected set of STUNner Gateways: it is possible to return all public TURN URIs per Kubernetes namespace, select a particular STUNner Gateways within a namespace, or specify exactly which STUNner Gateway listener (say, TCP or UDP) the returned credential should apply to. This allows to direct users to access the Kubernetes cluster via a specific STUNner listener.
4329

4430
The main use of this service is by a WebRTC application server to generate an [ICE server
4531
configuration](https://developer.mozilla.org/en-US/docs/Web/API/RTCIceServer) to be returned to

internal/client/client.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

internal/client/doc.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
//go:generate oapi-codegen -package client -generate "client" -o client.go ../../api/stunner.yaml
2+
3+
package client

pkg/types/doc.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
//go:generate oapi-codegen -package types -generate "types" -o types.go ../../api/stunner.yaml
2+
3+
package types

pkg/types/types.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)