many-television-17079
04/28/2023, 7:36 PMworried-knife-31967
04/29/2023, 11:25 AMwhite-architect-1595
05/01/2023, 5:29 PMbrash-musician-70232
05/03/2023, 4:22 AMsubscription_id = 00000000-0000-0000-0000-000000000000
role_definition_id = "/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Authorization/roleDefinitions/b24988ac-6180-42a0-ab88-20f7382dd24c"
role_assignment_name = azure.authorization.get_role_definition(
scope=f"/subscriptions/{subscription_id}",
role_definition_id=role_definition_id,
).name
However I get error message like :
In the error message it is seen that few things are getting repeated, not sure why.
RBAC name Error: invoke of azure-native:authorization:getRoleDefinition failed: invocation of azure-native:authorization:getRoleDefinition returned an error: request failed /%2Fsubscriptions%2F00000000-0000-0000-0000-000000000000/providers/Microsoft.Authorization/roleDefinitions/%2Fsubscriptions%2F00000000-0000-0000-0000-000000000000%2Fproviders%2FMicrosoft.Authorization%2FroleDefinitions%2Fb24988ac-6180-42a0-ab88-20f7382dd24c: autorest/azure: Service returned an error. Status=404 <nil>
adorable-scooter-32619
05/08/2023, 5:28 AM<http://github.com/pulumi/pulumi-azure-native-sdk/storage|github.com/pulumi/pulumi-azure-native-sdk/storage> v1.102.0
import (
"fmt"
"<http://github.com/pulumi/pulumi-azure-native-sdk/storage|github.com/pulumi/pulumi-azure-native-sdk/storage>"
"<http://github.com/pulumi/pulumi/sdk/v3/go/pulumi|github.com/pulumi/pulumi/sdk/v3/go/pulumi>"
"<http://github.com/pulumi/pulumi/sdk/v3/go/pulumi/config|github.com/pulumi/pulumi/sdk/v3/go/pulumi/config>"
"strings"
)
_, err := storage.NewManagementPolicy(ctx,
fmt.Sprintf("%v-management-policy",
storageAccountNamePulumi),
&storage.ManagementPolicyArgs{
AccountName: storageAccount.Name,
ResourceGroupName: pulumi.String(sa.ResourceGroupName),
ManagementPolicyName: pulumi.String("delete"),
Policy: &storage.ManagementPolicySchemaArgs{
Rules: &storage.ManagementPolicyRuleArray{
&storage.ManagementPolicyRuleArgs{
Enabled: pulumi.Bool(true),
Name: pulumi.String("DeleteRule"),
Type: pulumi.String("Lifecycle"),
Definition: &storage.ManagementPolicyDefinitionArgs{
Actions: &storage.ManagementPolicyActionArgs{
Version: &storage.ManagementPolicyVersionArgs{
Delete: &storage.DateAfterCreationArgs{
DaysAfterCreationGreaterThan: pulumi.Float64(30),
},
},
},
},
},
},
},
},
pulumi.Parent(storageAccount),
Output:
+ └─ azure-native:storage:ManagementPolicy infra-poc-dev-storage-account-files-management-policy **creating failed** 1 error
Diagnostics:
azure-native:storage:ManagementPolicy (infra-poc-dev-storage-account-files-management-policy):
error: autorest/azure: Service returned an error. Status=404 Code="HttpResourceNotFound" Message="The request url <https://management.azure.com/subscriptions/25bdf887-1695-4563-bdeb-bb568e0246c8/resourceGroups/infra-poc-dev/providers/Microsoft.Storage/storageAccounts/infrapocdevfiles/managementPolicies/delete?api-version=2021-02-01> is not found."
Thanks :)great-byte-67992
05/08/2023, 6:16 AM@pulumi/azure
v4 to v5 and I'm running into a panic from the terraform provider:
panic: interface conversion: interface {} is nil, not []interface {}
goroutine 88 [running]:
<http://github.com/hashicorp/terraform-provider-azurerm/internal/services/containers/migration.KubernetesClusterV1ToV2.UpgradeFunc.func1({0x7ae1400|github.com/hashicorp/terraform-provider-azurerm/internal/services/containers/migration.KubernetesClusterV1ToV2.UpgradeFunc.func1({0x7ae1400>?, 0xc00040cf90?}, 0x669bb80?, {0xc002184990?, 0x7ae1400?})
/home/runner/go/pkg/mod/github.com/pulumi/terraform-provider-azurerm@v1.41.1-0.20230214191339-39b1d1d475ad/internal/services/containers/migration/kubernetes_cluster.go:1231 +0x2fe
<http://github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk.StateUpgrades.func1({0x7adef78|github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk.StateUpgrades.func1({0x7adef78>, 0xc000138028}, 0x2?, {0x6622f40, 0xc00041dc00})
/home/runner/go/pkg/mod/github.com/pulumi/terraform-provider-azurerm@v1.41.1-0.20230214191339-39b1d1d475ad/internal/tf/pluginsdk/state_upgrades.go:52 +0x64
<http://github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.UpgradeJSONState({0x7adef78|github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.UpgradeJSONState({0x7adef78>, 0xc000138028}, 0x0?, 0xc001480d80?, 0xc000efc2a0?, {0x6622f40, 0xc00041dc00})
/home/runner/go/pkg/mod/github.com/pulumi/terraform-plugin-sdk/v2@v2.0.0-20220824175045-450992f2f5b9/helper/schema/grpc_provider.go:449 +0xa7
I searched the slack archive and found 2 other people mention it but no followup solutions
1. https://archive.pulumi.com/t/8205008/Hey-all-We-recently-updated-azure-classic-golang-from-v4-to-
2. https://archive.pulumi.com/t/2751297/Hi-All-Please-help-When-upgrading-pulumi-azure-from-4-to-5-I
I can't find the corresponding version of the code in <http://github.com/pulumi/terraform-provider-azurerm|github.com/pulumi/terraform-provider-azurerm>
because there's no v1.41.1
tag and that number seems wrong (in the logs) given v5 of the @pulumi/azure
package is using the provider at version 5.35.0
If I look at the code for 5.35.0
then it seems like there's a nil reference issue on this line of code: https://github.com/pulumi/terraform-provider-azurerm/blob/upstream-v3.35.0/internal/services/containers/migration/kubernetes_cluster.go#L1231
In my pulumi state i have the following under the state outputs for my cluster
"roleBasedAccessControl": {
"azureActiveDirectory": null,
"enabled": true
},
And verbose pulumi output shows that it's being passed as a terraform input to the provider
I0508 15:44:02.523773 1459043 log.go:75] eventSink::Infoerr(<{%reset%}>I0508 15:44:02.523744 1459133 schema.go:492] Created Terraform input: role_based_access_control = map[enabled:true]
I also tried removing the field from the state file and attempting to preview on that but it still fails with the same panic on the same line.
Has anyone else hit this issue and know the solution?wooden-accountant-88477
05/09/2023, 1:34 PMcold-midnight-30607
05/11/2023, 7:40 AMerror: autorest/Client#Do: Preparing request failed: StatusCode=0 -- Original Error: clientCredentialsToken: received HTTP status 401 with response: {"error":"invalid_client","error_description":"AADSTS7000215: Invalid client secret provided. Ensure the secret being sent in the request is the client secret value, not the client secret ID, for a secret added to app 'XXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX'
Has anyone come across this? It seems like Pulumi is still attempting to authenticate using the service principal and not the Azure CLI account.
Thanks!incalculable-bear-16978
05/12/2023, 2:46 PMgray-vr-25374
05/15/2023, 8:19 AMfancy-artist-45287
05/15/2023, 8:53 AMazure_native.devices.listIotHubResourceKeys
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const resourceGroupName = "example-rg";
const iotHubName = "example-iothub";
const iotHubKeys = pulumi.all([resourceGroupName, iotHubName]).apply(([rgName, iotName]) =>
azure_native.devices.listIotHubResourceKeys({
resourceGroupName: rgName,
resourceName: iotName,
}),
);
iotHubKeys.apply((keys) => {
for (const key of keys.value) {
console.log(`KeyName: ${key.keyName}, Rights: ${key.rights}`);
}
});
export const iotHubResourceKeys = iotHubKeys;
but I get the following exception: unrecognized data function (Invoke): azure-nativedeviceslistIotHubResourceKeys
Diagnostics:
pulumi:pulumi:Stack (DDSConnected-dev):
error: Error: invocation of azure-native:devices:listIotHubResourceKeys returned an error: unrecognized data function (Invoke): azure-native:devices:listIotHubResourceKeys
at Object.callback (C:\dev\DDS\DDSConnected\Infrastructure\node_modules\@pulumi\runtime\invoke.ts:172:37)
at Object.onReceiveStatus (C:\dev\DDS\DDSConnected\Infrastructure\node_modules\@grpc\grpc-js\src\client.ts:356:26)
at Object.onReceiveStatus (C:\dev\DDS\DDSConnected\Infrastructure\node_modules\@grpc\grpc-js\src\client-interceptors.ts:455:34)
at Object.onReceiveStatus (C:\dev\DDS\DDSConnected\Infrastructure\node_modules\@grpc\grpc-js\src\client-interceptors.ts:417:48)
at C:\dev\DDS\DDSConnected\Infrastructure\node_modules\@grpc\grpc-js\src\resolving-call.ts:111:24
at processTicksAndRejections (node:internal/process/task_queues:78:11)
The same goes for azure-native.devices.listIotHubResourceKeysForKeyName
ripe-school-9827
05/15/2023, 7:01 PMpulumi import azure-native:resources:resourceGroup [RESOURCE_GROUP_NAME] /subscription/[SUBSCRIPTION_ID]
However I'm getting the following error:
error: Preview failed: autorest/azure: Service returned an error. Status=400 Code="MissingApiVersionParameter" Message="The api-version query parameter (?api-version=) is required for all requests."
Any pointers where I am going wrong would be most appreciatedcalm-doctor-76791
05/17/2023, 1:19 PMastonishing-exabyte-93491
05/18/2023, 1:49 PMazure classic provider
support RecordSet
provisioning?curved-dentist-72931
05/19/2023, 6:59 PMmagnificent-sugar-64951
05/21/2023, 9:49 AMmagnificent-sugar-64951
05/21/2023, 9:57 AMfancy-artist-45287
05/24/2023, 3:30 PMrough-morning-53309
05/24/2023, 10:53 PMred-airline-54646
05/25/2023, 6:26 AMadventurous-butcher-54166
05/25/2023, 11:47 AMpulumi_azure_native
Python package - latest release v.1.102.0
and need to use the 2022-11-01
API spec version for Microsoft.Network
but it's not present in the Python package. Not sure how the structure works within the repository for enabled API specs but this spec seems to have been added to v1-removed.json last month with this commit from @melodic-tomato-39005. Also see that the nightly-sdk-generation build has been failing for the 2 weeks but don't know if that is connected.
Any tips or tricks on how I would go about this?nice-application-79035
05/25/2023, 7:46 PMdamp-honey-93158
05/29/2023, 3:43 AMcuddly-napkin-89521
05/30/2023, 7:58 AMearly-oil-32855
05/30/2023, 12:21 PMpulumi up
against our existing AKS with no code changed:
Previewing update ([redacted]/dev)
View in Browser (Ctrl+O): <https://app.pulumi.com/[redacted]/azure-kubernetes/dev/previews/2ab6b03c-327c-48a6-a3a0-5280c05e66a3>
Type Name Plan Info
pulumi:pulumi:Stack azure-kubernetes-dev
└─ azuread:index:Application infra-poc-dev-aks-application 1 error
Diagnostics:
azuread:index:Application (infra-poc-dev-aks-application):
error: unmarshaling urn:pulumi:dev::azure-kubernetes::pulumi:pulumi:StackReference$azuread:index/application:Application::infra-poc-dev-aks-application's instance state: could not read field public_client: '' expected type 'string', got unconvertible type 'map[string]interface {}', value: 'map[redirect_uris:[]]'
With our Go code looking like this:
package azure
import (
"<http://github.com/pulumi/pulumi-azuread/sdk/v4/go/azuread|github.com/pulumi/pulumi-azuread/sdk/v4/go/azuread>"
"<http://github.com/pulumi/pulumi/sdk/v3/go/pulumi|github.com/pulumi/pulumi/sdk/v3/go/pulumi>"
)
func CreateApplication(
ctx *pulumi.Context,
name string,
opts ...pulumi.ResourceOption,
) (*azuread.Application, error) {
// * <https://www.pulumi.com/registry/packages/azuread/api-docs/application/>
application, err := azuread.NewApplication(
ctx,
name,
&azuread.ApplicationArgs{
DisplayName: pulumi.String(name),
},
opts...,
)
if err != nil {
return nil, err
}
return application, nil
}
In my current understanding this is related to the fact that both PublicClient
and GroupMembershipClaims
were deprecated in azuread.ApplicationArgs
and are using a different types in newer Azure AD implementations. But I have no idea how to fix the error above because we are not configuring both explicitly.
Thanks :)curved-eye-56312
05/30/2023, 3:20 PMlittle-photographer-8552
05/31/2023, 11:53 AMautorest/azure: Service returned an error. Status=<nil> Code="PropertyChangeNotAllowed" Message="Changing property 'imageReference' is not allowed." Target="imageReference"
Now I changed our code and added this snippet:
, new CustomResourceOptions()
{
ReplaceOnChanges = new List<string>() { "imageReference" }
}
So that new our code looks like this:
DnsForwarder = new VirtualMachine($"{NamePrefix}-vm-dns-forwarder",
new VirtualMachineArgs
{
HardwareProfile = new HardwareProfileArgs
{
VmSize = VirtualMachineSizeTypes.Basic_A0
},
Location = PrimaryLocation,
NetworkProfile = new Pulumi.AzureNative.Compute.Inputs.NetworkProfileArgs
{
NetworkInterfaces =
{
new NetworkInterfaceReferenceArgs
{
Id = networkInterface.Id,
},
},
},
OsProfile = new OSProfileArgs
{
AdminPassword = vmAdminPassword.Result,
AdminUsername = "hubdnsvm-admin",
ComputerName = vmName
},
ResourceGroupName = args.ResourceGroupName,
StorageProfile = new StorageProfileArgs
{
ImageReference = new ImageReferenceArgs
{
Offer = "UbuntuServer",
Publisher = "Canonical",
Sku = "20.04-LTS",
Version = "latest",
},
OsDisk = new OSDiskArgs
{
Caching = CachingTypes.ReadWrite,
CreateOption = DiskCreateOptionTypes.FromImage
},
},
VmName = vmName,
Tags = GlobalTags,
AvailabilitySet = new Pulumi.AzureNative.Compute.Inputs.SubResourceArgs
{
Id = availabilitySet.Id
},
}, new CustomResourceOptions()
{
ReplaceOnChanges = new List<string>() { "imageReference" }
}
);
Yet, we keep getting the same error message. Any suggestions here on what we do wrong?brash-musician-70232
06/01/2023, 4:24 AM"Code="Failed" Message="The async operation failed."
On subsequent attempt I am getting error like "Code="DropLogicalServerAlreadyInProgress" Message="Server is already being dropped"
Any idea on what could be the issue?cuddly-napkin-89521
06/01/2023, 6:54 AMancient-solstice-53934
06/01/2023, 12:18 PM