Skip to content

Commit

Permalink
GetS3Credentials pass profile from config to NewSharedCredentials
Browse files Browse the repository at this point in the history
Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
  • Loading branch information
kaovilai committed Jul 28, 2023
1 parent 9c8275e commit 289aae1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelogs/unreleased/6558-kaovilai
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Non default s3 credential profiles work on Unified Repository Provider (kopia)
2 changes: 1 addition & 1 deletion pkg/repository/config/aws.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ func GetS3Credentials(config map[string]string) (*credentials.Value, error) {
return nil, errors.New("missing credential file")
}

creds := credentials.NewSharedCredentials(credentialsFile, "")
creds := credentials.NewSharedCredentials(credentialsFile, config[awsProfileKey])
credValue, err := creds.Get()
if err != nil {
return nil, err
Expand Down

0 comments on commit 289aae1

Please sign in to comment.