purple-train-14007
03/08/2024, 1:00 AMhundreds-gpu-71155
03/08/2024, 5:00 PMwooden-army-44126
03/09/2024, 3:29 PMwooden-army-44126
03/09/2024, 3:30 PMwooden-army-44126
03/09/2024, 3:37 PMwooden-army-44126
03/11/2024, 5:58 AMwooden-army-44126
03/11/2024, 6:02 AMadventurous-butcher-54166
03/11/2024, 12:44 PMpurple-train-14007
03/11/2024, 4:28 PM+ azure-native:network:VirtualNetwork VDI-Lab creating (0s) error: cannot check existence of resource '/subscriptions/***/resourceGroups/Calling%20%5BtoString%5D%20on%20an%20%5BOutput%3CT%3E%5D%20is%20not%20supported.%0A%0ATo%20get%20the%20value%20of%20an%20Output%3CT%3E%20as%20an%20Output%3Cstring%3E%20consider%20either%3A%0A1%3A%20o.apply%28v%20%3D%3E%20%60prefix%24%7Bv%7Dsuffix%60%29%0A2%3A%20pulumi.interpolate%20%60prefix%24%7Bv%7Dsuffix%60%0A%0ASee%20https%3A%2F%2Fwww.pulumi.com%2Fdocs%2Fconcepts%2Finputs-outputs%20for%20more%20details.%0AThis%20function%20may%20throw%20in%20a%20future%20version%20of%20%40pulumi%2Fpulumi./providers/Microsoft.Network/virtualNetworks/VDI-Lab': status code 400, <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""<http://www.w3.org/TR/html4/strict.dtd>">
purple-train-14007
03/11/2024, 4:31 PMerror: cannot check existence of resource '/subscriptions/77e25a38-44ad-4ce9-9bfe-595b0b38d7df/resourceGroups/Calling%20%5BtoString%5D%20on%20an%20%5BOutput%3CT%3E%5D%20is%20not%20supported.%0A%0ATo%20get%20the%20value%20of%20an%20Output%3CT%3E%20as%20an%20Output%3Cstring%3E%20consider%20either%3A%0A1%3A%20o.apply%28v%20%3D%3E%20%60prefix%24%7Bv%7Dsuffix%60%29%0A2%3A%20pulumi.interpolate%20%60prefix%24%7Bv%7Dsuffix%60%0A%0ASee%20https%3A%2F%2Fwww.pulumi.com%2Fdocs%2Fconcepts%2Finputs-outputs%20for%20more%20details.%0AThis%20function%20may%20throw%20in%20a%20future%20version%20of%20%40pulumi%2Fpulumi./providers/Microsoft.Network/virtualNetworks/VDI-Lab': status code 400, <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""<http://www.w3.org/TR/html4/strict.dtd>">
<HTML><HEAD><TITLE>Bad Request</TITLE>
<META HTTP-EQUIV="Content-Type" Content="text/html; charset=us-ascii"></HEAD>
<BODY><h2>Bad Request - Invalid URL</h2>
<hr><p>HTTP Error 400. The request URL is invalid.</p>
</BODY></HTML>
purple-train-14007
03/11/2024, 5:03 PMhundreds-gpu-71155
03/11/2024, 5:22 PMhundreds-gpu-71155
03/11/2024, 5:27 PMpurple-train-14007
03/11/2024, 5:48 PMpurple-train-14007
03/11/2024, 5:48 PMimport pulumi
import pulumi_azure_native as azure_native
virtual_network = azure_native.network.VirtualNetwork("virtualNetwork",
address_space=azure_native.network.AddressSpaceArgs(
address_prefixes=["10.0.0.0/16"],
),
flow_timeout_in_minutes=10,
location="eastus",
resource_group_name="rg1",
virtual_network_name="test-vnet")
purple-train-14007
03/11/2024, 5:49 PMhundreds-gpu-71155
03/11/2024, 5:49 PMOutput
correctly inside the class, but it's possible that Pulumi/azure still doesn't like subclassing after you fix thathundreds-gpu-71155
03/11/2024, 5:50 PMpurple-train-14007
03/11/2024, 5:51 PMhundreds-gpu-71155
03/11/2024, 5:52 PMpurple-train-14007
03/11/2024, 5:54 PMhundreds-gpu-71155
03/11/2024, 5:56 PMpurple-train-14007
03/11/2024, 6:00 PMhundreds-gpu-71155
03/11/2024, 8:45 PMpulumi_azure_native.network.ApplicationGateway
without shenanigans because you need a bunch of self-referential IDs inside its configuration.hundreds-gpu-71155
03/12/2024, 4:32 PMmost-waiter-72594
03/12/2024, 8:37 PMhundreds-gpu-71155
03/12/2024, 11:43 PMpulumi_azure_native.compute.VirtualMachine
? I was thinking I had to pass VirtualMachine.network_profile.network_interfaces
to ...network.get_network_interface_output()
, but azure doesn't seem to like thatastonishing-cpu-1506
03/13/2024, 8:18 AMadventurous-butcher-54166
03/13/2024, 9:29 AMmany-pager-46142
03/15/2024, 2:53 PMfrom pulumi_azure_native import storage, resources
from pulumi_azure_native.authorization import RoleAssignment
from pulumi_azure_native.storage import StorageAccount, FileShare
from pulumi_azure_native.containerinstance import ContainerGroup, VolumeMountArgs, ContainerArgs
SUBSCRIPTION_ID = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
STORAGE_BLOB_DATA_CONTRIBUTOR = "ba92f5b4-2d11-453d-a403-e96b0029c9fe"
resource_group = resources.ResourceGroup("ResourceGroup")
storage_account = StorageAccount(
"Storage",
minimum_tls_version="TLS1_2",
account_name="storageacct",
allow_blob_public_access=False,
allow_shared_key_access=False,
resource_group_name=resource_group.name,
sku=storage.SkuArgs(name=storage.SkuName.STANDARD_LRS),
kind=storage.Kind.STORAGE_V2,
azure_files_identity_based_authentication={
"directory_service_options": "AADDS",
"default_share_permission": "StorageFileDataSmbShareContributor"
}
)
fileshare = FileShare(
"Fileshare",
share_name="fileshare",
account_name=storage_account.name,
resource_group_name=resource_group.name,
share_quota=1
)
caddy_container = ContainerArgs(
name="caddy",
image="caddy",
resources={"requests": {"memory_in_gb": .5, "cpu": .5}},
ports=[{"port": 80}, {"port": 443}],
volume_mounts=[
VolumeMountArgs(mount_path="/config", name="caddy-config", read_only=False),
],
)
container_group = ContainerGroup(
"ContainerGroup",
container_group_name="container-group",
containers=[caddy_container],
ip_address={
"ports": [{"port": 80}, {"port": 443}],
"type": "Public",
"dns_name_label": "label",
"auto_generated_domain_name_label_scope": "unsecure"
},
os_type="Linux",
resource_group_name=resource_group.name,
location=resource_group.location,
restart_policy="OnFailure",
volumes=[{
"name": "caddy-config",
"azure_file": {
"share_name": fileshare.name,
"storage_account_name": storage_account.name,
"read_only": False,
}
}],
identity={"type": "SystemAssigned"},
)
role_assignment = RoleAssignment(
"RoleAssignment",
scope=storage_account.id,
role_definition_id=f"/subscriptions/{SUBSCRIPTION_ID}/providers/Microsoft.Authorization/roleDefinitions/{STORAGE_BLOB_DATA_CONTRIBUTOR}",
principal_id=container_group.identity.apply(lambda identity: identity.principal_id),
principal_type="ServicePrincipal"
)
The above code gives the error
Diagnostics:
pulumi:pulumi:Stack (test):
error: update failed
azure-native:containerinstance:ContainerGroup (TestContainerGroup):
error: Code="InvalidStorageAccountKey" Message="The Azure storage account key in volume 'caddy-config' is invalid."