Skip to content

Commit

Permalink
Added license information
Browse files Browse the repository at this point in the history
Signed-off-by: Abhijit Mukherjee <abhijit.mukherjee@infracloud.io>
  • Loading branch information
mabhi committed Dec 5, 2023
1 parent 5cf8fe8 commit 7e3024b
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/blockstorage/azure/auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ func NewClientCredentialsConfig(clientID string, clientSecret string, tenantID s
Resource: cloud.AzurePublic.Services[cloud.ResourceManager].Endpoint,
//Todo: find a replacement for the AADEndpoint in the new azure sdk
AADEndpoint: cloud.AzurePublic.Services[ActiveDirectory].Endpoint,
//azure.PublicCloud.ActiveDirectoryEndpoint,
// azure.PublicCloud.ActiveDirectoryEndpoint,
}
}

Expand Down
5 changes: 3 additions & 2 deletions pkg/blockstorage/azure/azuredisk.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
// Related Ticket- https://github.com/kanisterio/kanister/issues/1684
//
//nolint:staticcheck

package azure

import (
Expand Down Expand Up @@ -272,7 +273,7 @@ func isMigrateStorageAccountorKey(migrateStorageAccount, migrateStorageKey strin
return migrateStorageAccount == "" || migrateStorageKey == ""
}

func (s *AdStorage) revokeAccess(ctx context.Context, rg, name, ID string) {
func (s *AdStorage) revokeAccess(ctx context.Context, rg, name, id string) {
poller, err := s.azCli.SnapshotsClient.BeginRevokeAccess(ctx, rg, name, nil)
if err != nil {
log.Print("Failed to finish the revoke request", field.M{"error": err.Error()})
Expand All @@ -283,7 +284,7 @@ func (s *AdStorage) revokeAccess(ctx context.Context, rg, name, ID string) {
}

if err != nil {
log.Print("Failed to revoke access from snapshot", field.M{"snapshot": ID})
log.Print("Failed to revoke access from snapshot", field.M{"snapshot": id})
}
}

Expand Down
14 changes: 14 additions & 0 deletions pkg/blockstorage/azure/environments.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
// Copyright 2019 The Kanister Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package azure

import (
Expand Down
14 changes: 14 additions & 0 deletions pkg/blockstorage/helper_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
// Copyright 2019 The Kanister Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package blockstorage

import (
Expand Down

0 comments on commit 7e3024b

Please sign in to comment.