Skip to content

Commit

Permalink
3026: lint fixes
Browse files Browse the repository at this point in the history
Signed-off-by: russellcain <[email protected]>
  • Loading branch information
russellcain committed Sep 17, 2024
1 parent 81b3c8e commit a87f77d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions cmd/cdi-importer/importer.go
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ func newDataSource(source string, contentType string, volumeMode v1.PersistentVo
ep, _ := util.ParseEnvVar(common.ImporterEndpoint, false)
acc, _ := util.ParseEnvVar(common.ImporterAccessKeyID, false)
sec, _ := util.ParseEnvVar(common.ImporterSecretKey, false)
service_account, _ := util.ParseEnvVar(common.ImporterServiceAccountName, false)
serviceAccount, _ := util.ParseEnvVar(common.ImporterServiceAccountName, false)
keyf, _ := util.ParseEnvVar(common.ImporterGoogleCredentialFileVar, false)
diskID, _ := util.ParseEnvVar(common.ImporterDiskID, false)
uuid, _ := util.ParseEnvVar(common.ImporterUUID, false)
Expand Down Expand Up @@ -289,7 +289,7 @@ func newDataSource(source string, contentType string, volumeMode v1.PersistentVo
ds *importer.S3DataSource
err error
)
if service_account != "" {
if serviceAccount != "" {
// use this as a flag to say the user has a SAN set up with creds that IRSA will read
klog.Infof("Attempting to create your S3 Data Source with cloud provider creds.\n")
ds, err = importer.NewChainCredentialsS3DataSource(ep, certDir)
Expand Down
2 changes: 1 addition & 1 deletion pkg/importer/s3-datasource.go
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ func getS3Client(endpoint string, accessKey string, secKey string, certDir strin
if err != nil {
return nil, errors.Wrap(err, "Error creating http client for s3")
}
var creds *credentials.Credentials = nil
var creds *credentials.Credentials
if accessKey != emptyAccessKey && secKey != emptySecretKey {
creds = credentials.NewStaticCredentials(accessKey, secKey, "")
}
Expand Down

0 comments on commit a87f77d

Please sign in to comment.