Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions data/data/install.openshift.io_installconfigs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5483,8 +5483,8 @@ spec:
allowSharedKeyAccess:
description: |-
AllowSharedKeyAccess specifies if shared access key should be enabled for the storage account.
Default value is true.
Disabling this will require a new permission "Storage Blob Data Contributor" in azure.
Default value is false.
Needs the permission "Storage Blob Data Contributor" in azure.
type: boolean
armEndpoint:
description: ARMEndpoint is the endpoint for the Azure API when
Expand Down
4 changes: 2 additions & 2 deletions pkg/explain/printer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -317,8 +317,8 @@ cluster itself may not include these tags.
desc: `FIELDS:
allowSharedKeyAccess <boolean>
AllowSharedKeyAccess specifies if shared access key should be enabled for the storage account.
Default value is true.
Disabling this will require a new permission "Storage Blob Data Contributor" in azure.
Default value is false.
Needs the permission "Storage Blob Data Contributor" in azure.

armEndpoint <string>
ARMEndpoint is the endpoint for the Azure API when installing on Azure Stack.
Expand Down
6 changes: 3 additions & 3 deletions pkg/infrastructure/azure/azure.go
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ func (p *Provider) InfraReady(ctx context.Context, in clusterapi.InfraReadyInput
var storageClientFactory *armstorage.ClientFactory
var storageAccountKeys []armstorage.AccountKey

sharedKey := true
sharedKey := false
if in.InstallConfig.Config.Azure.AllowSharedKeyAccess != nil {
sharedKey = *in.InstallConfig.Config.Azure.AllowSharedKeyAccess
}
Expand Down Expand Up @@ -850,7 +850,7 @@ func (p Provider) Ignition(ctx context.Context, in clusterapi.IgnitionInput) ([]
return nil, fmt.Errorf("failed to create service client: %w", err)
}

sharedKey := true
sharedKey := false
if in.InstallConfig.Config.Azure.AllowSharedKeyAccess != nil {
sharedKey = *in.InstallConfig.Config.Azure.AllowSharedKeyAccess
}
Expand Down Expand Up @@ -905,7 +905,7 @@ func (p Provider) Ignition(ctx context.Context, in clusterapi.IgnitionInput) ([]
}
}
if sasURL == "" && !sharedKey {
udc, err := serviceClient.GetUserDelegationCredential(context.Background(), info, nil)
udc, err := serviceClient.GetUserDelegationCredential(ctx, info, nil)
if err != nil {
return nil, fmt.Errorf("failed to create user delegation credentials: %w", err)
}
Expand Down
5 changes: 3 additions & 2 deletions pkg/types/azure/platform.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,9 @@ type Platform struct {
BaseDomainResourceGroupName string `json:"baseDomainResourceGroupName,omitempty"`

// AllowSharedKeyAccess specifies if shared access key should be enabled for the storage account.
// Default value is true.
// Disabling this will require a new permission "Storage Blob Data Contributor" in azure.
// Default value is false.
// Needs the permission "Storage Blob Data Contributor" in azure.
//
//
// +optional
AllowSharedKeyAccess *bool `json:"allowSharedKeyAccess,omitempty"`
Expand Down