Skip to content

Commit

Permalink
test commit for client ID and tenant ID env vars
Browse files Browse the repository at this point in the history
Signed-off-by: Ashutosh Kumar <[email protected]>
  • Loading branch information
sonasingh46 committed May 13, 2023
1 parent b31fe6f commit 442971d
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions azure/scope/identity.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ package scope
import (
"context"
"fmt"
"os"
"reflect"
"strings"

Expand Down Expand Up @@ -147,6 +148,12 @@ func (p *AzureCredentialsProvider) GetAuthorizer(ctx context.Context, resourceMa
WithTenantID(p.Identity.Spec.TenantID).
WithClientID(p.Identity.Spec.ClientID).
WithDefaults()
// ToDo: Remove the env var setting before merging. Just for testing
// Ref: https://kubernetes.slack.com/archives/CEX9HENG7/p1683983584649619
os.Setenv(AzureTenantIDEnvKey, p.Identity.Spec.TenantID)
os.Setenv(AzureClientIDEnvKey, p.Identity.Spec.ClientID)
//----------------------------------------------------------------------

if err != nil {
return nil, errors.Wrapf(err, "failed to setup azwi options for identity %s", p.Identity.Name)
}
Expand Down

0 comments on commit 442971d

Please sign in to comment.