Skip to content

Commit 77230f1

Browse files
committed
remove oidc instrument
1 parent d1037c9 commit 77230f1

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

cli/server.go

+9-3
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ import (
103103
"github.com/coder/wgtunnel/tunnelsdk"
104104
)
105105

106-
func createOIDCConfig(ctx context.Context, instrument *promoauth.Factory, vals *codersdk.DeploymentValues) (*coderd.OIDCConfig, error) {
106+
func createOIDCConfig(ctx context.Context, vals *codersdk.DeploymentValues) (*coderd.OIDCConfig, error) {
107107
if vals.OIDC.ClientID == "" {
108108
return nil, xerrors.Errorf("OIDC client ID must be set!")
109109
}
@@ -160,7 +160,7 @@ func createOIDCConfig(ctx context.Context, instrument *promoauth.Factory, vals *
160160
}
161161

162162
return &coderd.OIDCConfig{
163-
OAuth2Config: instrument.New("oidc-login", useCfg),
163+
OAuth2Config: useCfg,
164164
Provider: oidcProvider,
165165
Verifier: oidcProvider.Verifier(&oidc.Config{
166166
ClientID: vals.OIDC.ClientID.String(),
@@ -642,7 +642,13 @@ func (r *RootCmd) Server(newAPI func(context.Context, *coderd.Options) (*coderd.
642642
logger.Warn(ctx, "coder will not check email_verified for OIDC logins")
643643
}
644644

645-
oc, err := createOIDCConfig(ctx, oauthInstrument, vals)
645+
// This OIDC config is **not** being instrumented with the
646+
// oauth2 instrument wrapper. If we implement the missing
647+
// oidc methods, then we can instrument it.
648+
// Missing:
649+
// - Userinfo
650+
// - Verify
651+
oc, err := createOIDCConfig(ctx, vals)
646652
if err != nil {
647653
return xerrors.Errorf("create oidc config: %w", err)
648654
}

0 commit comments

Comments
 (0)