AuthN: Set oauth client grant_types based on plugin state (#77248)

* Disable plugin service account

* Fix bug seen by linoman 💯

Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>

* Account for PR feedback

Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>

* Fix test data

* Enable datasource plugins by default

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>

* Update pkg/services/extsvcauth/oauthserver/oasimpl/service.go

* Handle error differently

* Fix service reg

---------

Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>
Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
This commit is contained in:
Gabriel MABILLE
2023-10-27 14:45:04 +02:00
committed by GitHub
co-authored by linoman Andres Martinez Gotor
parent 214535c1a9
commit 83e9088314
13 changed files with 226 additions and 77 deletions
@@ -530,8 +530,7 @@ func TestLoader_Load_ExternalRegistration(t *testing.T) {
},
ExternalServiceRegistration: &plugindef.ExternalServiceRegistration{
Impersonation: &plugindef.Impersonation{
Enabled: boolPtr(true),
Groups: boolPtr(true),
Groups: boolPtr(true),
Permissions: []plugindef.Permission{
{
Action: "read",