feat: add PSK for external provisionerd auth (#8877)

Signed-off-by: Spike Curtis <spike@coder.com>
This commit is contained in:
Spike Curtis
2023-08-04 12:32:28 +04:00
committed by GitHub
parent b77d6b2c84
commit cb4989cd8d
24 changed files with 429 additions and 61 deletions

View File

@ -56,6 +56,7 @@ type Options struct {
DontAddLicense bool
DontAddFirstUser bool
ReplicaSyncUpdateInterval time.Duration
ProvisionerDaemonPSK string
}
// New constructs a codersdk client connected to an in-memory Enterprise API instance.
@ -94,6 +95,7 @@ func NewWithAPI(t *testing.T, options *Options) (
Keys: Keys,
ProxyHealthInterval: options.ProxyHealthInterval,
DefaultQuietHoursSchedule: oop.DeploymentValues.UserQuietHoursSchedule.DefaultSchedule.Value(),
ProvisionerDaemonPSK: options.ProvisionerDaemonPSK,
})
require.NoError(t, err)
setHandler(coderAPI.AGPL.RootHandler)