[v11.0.x] CloudMigrations: Add instance metadata to auth token (#86371)

CloudMigrations: Add instance metadata to auth token (#85381)

* update how tokens are passed around

* rename structs

(cherry picked from commit 5a5f76ae0a)

Co-authored-by: Michael Mandrus <41969079+mmandrus@users.noreply.github.com>
This commit is contained in:
grafana-delivery-bot[bot]
2024-04-16 16:45:57 +01:00
committed by GitHub
co-authored by Michael Mandrus
parent fd4c86539b
commit 8de772e55d
4 changed files with 50 additions and 6 deletions
@@ -15,6 +15,10 @@ func (ss *sqlStore) MigrateDatasources(ctx context.Context, request *cloudmigrat
return nil, cloudmigration.ErrInternalNotImplementedError
}
func (ss *sqlStore) CreateMigration(ctx context.Context, token cloudmigration.Base64EncodedTokenPayload) error {
return nil
}
func (ss *sqlStore) GetAllCloudMigrations(ctx context.Context) ([]*cloudmigration.CloudMigration, error) {
var migrations = make([]*cloudmigration.CloudMigration, 0)
err := ss.db.WithDbSession(ctx, func(sess *db.Session) error { return sess.Find(&migrations) })