broad-morning-54433
09/23/2020, 9:12 PMoutput
method on azure.servicebus.Queue
? And my follow up question.... how can output bindings be configured on Service Bus Queues?high-wire-68732
09/23/2020, 10:44 PMerror: [WARN] A duplicate Security Group rule was found
Multiple times, once for each Listener.
Any idea how to be able to achieve this?
Here's a sample of what we are trying to do:
import * as awsx from '@pulumi/awsx';
const vpc = new awsx.ec2.Vpc('test-vpc', {
vpcId: '...',
});
// LOAD BALANCER DEFINITION
const lb = new awsx.lb.ApplicationLoadBalancer('testLB', {
vpc,
subnets: [
// ...
],
external: true,
tags: {
'Name': 'testLB'
},
});
// FIRST APP DEFINITION
const targetGroup1 = lb.createTargetGroup('testTG1', {
port: 80,
loadBalancer: lb,
healthCheck: {
path: '/api',
},
tags: {
'Name': 'testTG1'
},
});
const httpListener1 = lb.createListener('testHTTP1', {
defaultActions: [{
fixedResponse: {
contentType: 'text/plain',
statusCode: '404',
},
type: 'fixed-response',
}],
loadBalancer: lb,
port: 80,
protocol: 'HTTP',
external: true,
});
httpListener1.addListenerRule('testListener1', {
actions: [{
targetGroupArn: targetGroup1.targetGroup.arn,
type: 'forward',
}],
conditions: [
{
pathPattern: {
values: [
'/api/*',
],
},
},
],
priority: 200,
});
new awsx.ecs.FargateService('api', {
desiredCount: 1,
subnets: [
// ...
],
taskDefinitionArgs: {
tags: {
'Name': 'api'
},
containers: {
adminBackend: {
image: '...',
memory: 512,
portMappings: [
targetGroup1,
],
},
},
},
});
// SECOND APP DEFINITION
const targetGroup2 = lb.createTargetGroup('testTG2', {
port: 80,
loadBalancer: lb,
healthCheck: {
path: '/ui',
},
tags: {
'Name': 'testTG2'
},
});
const httpListener2 = lb.createListener('testHTTP2', {
defaultActions: [{
fixedResponse: {
contentType: 'text/plain',
statusCode: '404',
},
type: 'fixed-response',
}],
loadBalancer: lb,
port: 80,
protocol: 'HTTP',
external: true,
});
httpListener2.addListenerRule('testListener2', {
actions: [{
targetGroupArn: targetGroup2.targetGroup.arn,
type: 'forward',
}],
conditions: [
{
pathPattern: {
values: [
'/*',
],
},
},
],
priority: 200,
});
new awsx.ecs.FargateService('ui', {
desiredCount: 1,
subnets: [
// ...
],
taskDefinitionArgs: {
tags: {
'Name': 'ui'
},
containers: {
adminBackend: {
image: '...',
memory: 512,
portMappings: [
targetGroup2,
],
},
},
},
});
clever-plumber-29709
09/24/2020, 4:16 AMhelpful-processor-86468
09/24/2020, 11:08 AMerror: Exception calling application: code() takes at most 15 arguments (16 given)
- this is what I'm getting when using dynamic resource when trying to do pulumi destroy
. It was working fine for some time and now it's broken without any code change. What is happening?gorgeous-cpu-53034
09/24/2020, 12:07 PMbillions-greece-30724
09/24/2020, 1:52 PMPS C:\GitRepos\iac-pulumi\src\nvp-az-identity> pulumi preview
Previewing update (nvoicepay/production)
View Live: <https://app.pulumi.com/***/***-az-identity/production/previews/****>
Type Name Plan Info
pulumi:pulumi:Stack ***-az-identity-production 1 error
+ ├─ pulumi:providers:azuread Production create
= └─ azure:keyvault:KeyVault ***-prod-global-keyvault import 1 error
Diagnostics:
pulumi:pulumi:Stack (***-az-identity-production):
error: preview failed
azure:keyvault:KeyVault (***-prod-global-keyvault):
error: Preview failed: unrecognized resource type (Read): azure:keyvault/keyVault:KeyVault
billions-greece-30724
09/24/2020, 1:53 PMvar keyVault = new KeyVault(globalRegion.Configurator.GetKeyVaultName(), new KeyVaultArgs
{
Name = globalRegion.Configurator.GetKeyVaultName(),
Location = globalResourceGroup.Resource.Location,
ResourceGroupName = globalResourceGroup.Resource.Name,
TenantId = globalRegion.SharedConfig.TenantId,
SkuName = "standard",
//acc
EnabledForDiskEncryption = true,
EnabledForDeployment = true,
EnabledForTemplateDeployment = true,
}, new CustomResourceOptions
{
ImportId = NvpConfig.GlobalKeyVaultResourceId,
Provider = azProvider
}
);
red-energy-90711
09/24/2020, 2:41 PMclever-plumber-29709
09/24/2020, 3:17 PMhelpful-processor-86468
09/25/2020, 7:11 AMmammoth-insurance-9770
09/25/2020, 10:27 AMopts
argument which is then passed to the superconstructor:
class MyComponent(pulumi.ComponentResource):
def __init__(self, name, opts = None):
super().__init__('pkg:index:MyComponent', name, None, opts)
I was hopeful that this would cause Pulumi to apply those opts
to all the resources inside the ComponentResource
, so that if for example I wanted to use a custom provider, I only have to specify when creating my compontent resource:
my_component = MyComponent(opts=ResourceOptions(provider=my_provider))
But this doesn't seem to be the case. So, what is the appropriate way of propagating these options onward? Should I pass opts
into every child resource:
class MyComponent(pulumi.ComponentResource):
def __init__(self, name, opts = None):
super().__init__('pkg:index:MyComponent', name, None, opts)
my_resource1 = ResourceA(opts=opts)
my_resource2 = ResourceB(opts=opts)
Although, this makes life more difficult when I need to add additional fields to the ResourceOptions
of certain resources, such as depends_on
.
Or, should I pick out the fields that I want:
class MyComponent(pulumi.ComponentResource):
def __init__(self, name, opts = None):
super().__init__('pkg:index:MyComponent', name, None, opts)
my_resource1 = ResourceA(opts=ResourceOptions(provider=opts.provider))
my_resource2 = ResourceB(opts=ResourceOptions(provider=opts.provider))
which is OK, but I am concerned I will then by missing options which were supposed to be progagated down the tree. What was the intended usage here?
Thanks in advance 🙂proud-pizza-80589
09/25/2020, 12:34 PMconst bucket = new aws.s3.Bucket("my-bucket");
gifted-student-18589
09/25/2020, 3:50 PMmillions-furniture-75402
09/25/2020, 4:54 PM// systemBackupLambdaId = backupLambda.id exported from the other project
const systemBackupLambda = aws.lambda.Function.get("system-backup-lambda", systemBackupLambdaId);
I’m getting an error I don’t understand:
Diagnostics:
pulumi:pulumi:Stack (monitoring-service-sandbox):
error: preview failed
aws:lambda:Function (system-backup-lambda):
error: Preview failed: refreshing urn:pulumi:sandbox::monitoring-service::aws:lambda/function:Function::system-backup-lambda: 1 error occurred:
* InvalidParameter: 1 validation error(s) found.
- minimum field size of 1, GetFunctionInput.FunctionName.
clever-plumber-29709
09/25/2020, 4:57 PMbig-potato-91793
09/25/2020, 6:28 PMstraight-insurance-27894
09/25/2020, 7:31 PMaz login
.
This is an octopus deploy job using a service principal. The job uses the variables
$env:ARM_CLIENT_ID = $AzAccountClient
$env:ARM_CLIENT_SECRET = $AzAccountPassword
$env:ARM_TENANT_ID = $AzAccountTenantId
$env:ARM_SUBSCRIPTION_ID = $AzAccountSubscriptionNumber
We have dozens of deployments per week across 20 stacks that has been using this process. Its stable.
We are trying something new, creating privatelinks from subscription A to a vnet in subscription B. Since most of the code executes in subscription A, the env variable ARM_SUBSCRIPTION_ID is set to "A". However, when we get to the privatelink, we build a new provider and pass into the service principal the credentials, tenant, secret and subscription B. But when we use this new provider in the private link, we still get the same error. We know we have to pass in subscription B to privatelink. Older versions of the pulumi azure provider would default the credenatials, secret and tenant, but the newer version seems to require them.
@pulumi 2.1
@pulumi/azure 3.20.1
//Provider Code
const Sub = new vznaz.azure.Provider("subscription B", { //TODO
subscriptionId: "subscription B",
metadataHost: '<http://management.azure.com|management.azure.com>',
clientId: process.env["ARM_CLIENT_ID"],
clientSecret: process.env["ARM_CLIENT_SECRET"],
tenantId: vznaz.AADTenantId,
});
vznpulumi.pulumi.ProviderResource.register(Sub).then(p => p);
//PrivateLink Code that is failing with above error message
const privateLinkTags = TAGS;
const PrivateLinkSubnet = vznpulumi.pulumi.output(vznaz.azure.network.getSubnet({
resourceGroupName: 'vznz-net_rg',
virtualNetworkName: 'vznz-net_vnet',
name: 'private-link-hub01',
}, {
provider: Sub,
async: true,
}));
//sqlServer
const SqlPrivateLink = new vznaz.azure.privatelink.Endpoint('sql-link', { //was vznaz.azure.privatelink.Endpoint but was getting an error below that privateIpAddress didn't exist on SqlPrivateLink.privateServiceConnection.privateIpAddress
resourceGroupName: '_prod-rg-01',
privateServiceConnection: {
privateConnectionResourceId: sqlServer.id,
isManualConnection: false,
name: sqlServer.name,
subresourceNames: [ 'sqlServer' ],
},
subnetId: PrivateLinkSubnet.id,
name: sqlServer.name,
tags: privateLinkTags,
},{
provider: Sub,
});
We are stumped. Any help would be greatly appreciated.witty-vegetable-61961
09/25/2020, 9:46 PMchilly-magazine-6129
09/25/2020, 9:53 PMpulumi up
always updates lambdas (~code). Then:
pulumi refresh
always shows those same lambdas needing update. I let it update. Refreshing / Previewing says no changes need to happen.
I then change the memory size of one of the lambdas, but it triggers all Lambdas to update (~code), and one of them ~code + memorySize.
This happened recently - I'm using WSL2, I've diff-ed stack exports, and file sizes before and after - and I see nothing that stands out.
Any thoughts on what may be the issue or where I should look next?chilly-magazine-6129
09/25/2020, 9:54 PMadamant-dress-73325
09/25/2020, 10:52 PMdelightful-jordan-36077
09/25/2020, 11:35 PMbroad-keyboard-684
09/27/2020, 2:48 AMTo understand how to write and distribute your own plugins, please consult the relevant documentation.... here https://www.pulumi.com/docs/reference/cli/pulumi_plugin/ but I don't know where " the relevant documentation" is. Many thanks in advance.
curved-pharmacist-41509
09/27/2020, 5:04 AMwonderful-dog-9045
09/27/2020, 1:29 PMtsc
locally also detects the type issue.
Does anybody have any ideas what could contribute to typeissues being ignored by the pulumi runtime locally?wet-noon-14291
09/28/2020, 6:56 AMpulumi up
or will pulumi just check its own state when deploying and not seeing the change? If yes, does that apply to all types of resources?bitter-application-91815
09/28/2020, 9:30 AMbitter-application-91815
09/28/2020, 9:30 AMbitter-application-91815
09/28/2020, 12:21 PMbitter-application-91815
09/28/2020, 12:22 PM