mirror of
https://github.com/juanfont/headscale.git
synced 2026-09-17 14:02:07 +09:00
integration/hsic: add CreateOAuthClient via the v2 API client
Mints an admin API key and creates a keyType=client OAuth credential through gen/client/v2, exposed on ControlServer. Reusable by tests needing OAuth client credentials.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package integration
|
||||
|
||||
import (
|
||||
"context"
|
||||
"net/netip"
|
||||
|
||||
clientv1 "github.com/juanfont/headscale/gen/client/v1"
|
||||
@@ -22,6 +23,8 @@ type ControlServer interface {
|
||||
ConnectToNetwork(network *dockertest.Network) error
|
||||
GetHealthEndpoint() string
|
||||
GetEndpoint() string
|
||||
GetIPEndpoint() string
|
||||
CreateOAuthClient(ctx context.Context, scopes, tags []string) (string, string, error)
|
||||
WaitForRunning() error
|
||||
Restart() error
|
||||
CreateUser(user string) (*clientv1.User, error)
|
||||
|
||||
Reference in New Issue
Block a user