https://pulumi.com logo
Docs
Join the conversationJoin Slack
Channels
announcements
automation-api
aws
azure
blog-posts
built-with-pulumi
cloudengineering
cloudengineering-support
content-share
contribex
contribute
docs
dotnet
finops
general
getting-started
gitlab
golang
google-cloud
hackathon-03-19-2020
hacktoberfest
install
java
jobs
kubernetes
learn-pulumi-events
linen
localstack
multi-language-hackathon
office-hours
oracle-cloud-infrastructure
plugin-framework
pulumi-cdk
pulumi-crosscode
pulumi-deployments
pulumi-kubernetes-operator
pulumi-service
pulumiverse
python
registry
status
testingtesting123
testingtesting321
typescript
welcome
workshops
yaml
Powered by Linen
general
  • b

    bright-helicopter-33718

    03/15/2022, 2:42 PM
    Hi everyone! Question regarding azure, how can I manually create an onEvent to a trigger through an
    ArchiveFunctionApp
    ?
  • c

    curved-action-42169

    03/15/2022, 3:33 PM
    đź‘‹ Hi everyone!
  • c

    curved-action-42169

    03/15/2022, 3:36 PM
    I'm working on setting up a new AWS build pipeline as exampled here: https://www.pulumi.com/docs/guides/continuous-delivery/aws-code-services/#buildspecyml Can someone point me the right direction, I'm getting an error on the BUILD phase that is kind of vague. "COMMAND_EXECUTION_ERROR: Error while executing command: update_pulumi_stack.sh. Reason: exit status 127"
  • r

    red-football-97286

    03/15/2022, 3:41 PM
    How are people structuring there pulumi Go project folders? What directories do you use? Go recommends folders like CMD, Internal.
    s
    • 2
    • 4
  • c

    curved-action-42169

    03/15/2022, 4:02 PM
    Here is the build log for where it failed at: [Container] 2022/03/15 15:56:47 Entering phase BUILD [Container] 2022/03/15 15:56:47 Running command npm install npm WARN read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but package-lock.json was generated for lockfileVersion@2. I'll try to do my best with it!
    node scripts/install-pulumi-plugin.js resource aws v4.38.1
    [resource plugin aws-4.38.1] installing Downloading plugin: 0 B / 96.61 MiB 0.00% Downloading plugin: 6.44 MiB / 96.61 MiB 6.66% 2s Downloading plugin: 14.27 MiB / 96.61 MiB 14.77% 2s Downloading plugin: 21.61 MiB / 96.61 MiB 22.37% 2s Downloading plugin: 28.77 MiB / 96.61 MiB 29.77% 1s Downloading plugin: 35.59 MiB / 96.61 MiB 36.83% 1s Downloading plugin: 42.65 MiB / 96.61 MiB 44.14% 1s Downloading plugin: 49.28 MiB / 96.61 MiB 51.01% 1s Downloading plugin: 61.25 MiB / 96.61 MiB 63.40% Downloading plugin: 77.83 MiB / 96.61 MiB 80.55% Downloading plugin: 92.16 MiB / 96.61 MiB 95.39% Downloading plugin: 96.61 MiB / 96.61 MiB 100.00% 2s
    node scripts/install-pulumi-plugin.js resource kubernetes v3.16.0
    [resource plugin kubernetes-3.16.0] installing Downloading plugin: 0 B / 30.27 MiB 0.00% Downloading plugin: 7.33 MiB / 30.27 MiB 24.22% Downloading plugin: 14.56 MiB / 30.27 MiB 48.09% Downloading plugin: 30.27 MiB / 30.27 MiB 100.00% 0s
    node scripts/postinstall
    added 150 packages from 235 contributors and audited 153 packages in 8.304s 33 packages are looking for funding run
    npm fund
    for details found 0 vulnerabilities [Container] 2022/03/15 15:57:00 Running command npm run build npm ERR! missing script: build npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2022-03-15T15_57_00_514Z-debug.log [Container] 2022/03/15 15:57:00 Command did not exit successfully npm
  • c

    curved-action-42169

    03/15/2022, 4:36 PM
    Issue resolved. There is a service role created for the specific build project. You must add the appropriate IAM permissions to that account to CRUD your infrastructure. Also buildspec.yml was cleaned up and simplified to be just this:
    version: 0.2
    
    phases:
      install:
        commands:
          # pulumi
          - curl -fsSL <https://get.pulumi.com/> | sh
          - export PATH=$PATH:$HOME/.pulumi/bin
      build:
        commands:
          - npm install
          - pulumi stack select dev
          - pulumi up --yes
  • r

    red-gold-2376

    03/15/2022, 9:37 PM
    Hello everyone, I hope everything is OK, I have this error using dynamic provider with
    true-myth
    library
    pulumi:pulumi:Stack (wordpress-dev):
        TypeError: Symbol.prototype [ @@toPrimitive ] requires that 'this' be a Symbol: TypeError: Symbol.prototype [ @@toPrimitive ] requires that 'this' be a Symbol
            at Symbol.[Symbol.toPrimitive] (<anonymous>)
            at Object.<anonymous> (<anonymous>:64:21)
            at Module._compile (node:internal/modules/cjs/loader:1099:14)
            at requireFromString (/home/abukamel/codebases/work/iac/pulumi/programs/wordpress/node_modules/require-from-string/index.js:28:4)
            at getProvider (/home/abukamel/codebases/work/iac/pulumi/programs/wordpress/node_modules/@pulumi/cmd/dynamic-provider/index.ts:66:20)
            at Object.<anonymous> (/home/abukamel/codebases/work/iac/pulumi/programs/wordpress/node_modules/@pulumi/cmd/dynamic-provider/index.ts:116:26)
            at Generator.next (<anonymous>)
            at /home/abukamel/codebases/work/iac/pulumi/programs/wordpress/node_modules/@pulumi/pulumi/cmd/dynamic-provider/index.js:21:71
            at new Promise (<anonymous>)
            at __awaiter (/home/abukamel/codebases/work/iac/pulumi/programs/wordpress/node_modules/@pulumi/pulumi/cmd/dynamic-provider/index.js:17:12)
     
        error: Symbol.prototype [ @@toPrimitive ] requires that 'this' be a Symbol
    The code works normally if it was not used directly without pulumi.
    export const getOrCreateMonitor = async (fqdn: string): Promise<Result<Monitor, string>> => {
        await checkApiKey()
        const currentMonitor = await getMonitor(fqdn)
        if (currentMonitor.isOk) {
            return currentMonitor
        }
        const alertContacts = await getAlertContacts()
        if (alertContacts.isErr) {
            return err(alertContacts.error)
        }
        const formattedAlertContacts = alertContacts.value.map((alertContact: AlertContact) => `${alertContact.id}_5_0`)
        const requestData =
            qs.stringify({
                ...sharedRequestData,
                type: '1',
                alert_contacts: formattedAlertContacts.join('-'),
                friendly_name: fqdn,
                url: `https://${fqdn}`
            })
        const response = await <http://axios.post|axios.post>(newMonitorUrl, requestData, sharedRequestConfig)
        if (response.data.stat != 'ok') {
            return err(response.data.error.message)
        }
        const newMonitor: Monitor = response.data.monitor
        return ok(newMonitor)
    }
    Is there a way to fix this?
  • b

    busy-island-31180

    03/15/2022, 9:49 PM
    I had a question on this: https://github.com/pulumi/pulumi/issues/8796 I was wondering if for this (and possibly other breaking changes), if pulumi could implement feature flags so that users could “subscribe” to these types of bug fixes?
  • b

    busy-telephone-91852

    03/15/2022, 11:19 PM
    Hi, I have been using Pulumi in the past 2-3 weeks to setup our infrastructure on AWS and it’s been great. We are considering setting up Amazon Managed Grafana. Wondering if there are any plans to configure Amazon Managed Grafana workspace using pulumi in the near future (apologies if I missed any discussion regarding this).
    s
    • 2
    • 2
  • a

    ancient-solstice-62300

    03/16/2022, 1:23 AM
    Hi everyone,
    đź‘‹ 2
    👋🏻 1
  • b

    busy-island-31180

    03/16/2022, 2:51 AM
    How do you create a mock resource? (in golang)
  • b

    busy-island-31180

    03/16/2022, 2:52 AM
    I just want some arbitrary resource that fits the
    pulumi.Resource
    interface
    e
    • 2
    • 2
  • a

    ancient-solstice-62300

    03/16/2022, 3:47 AM
    Just wondering if anyone else got this error, which only happens when I run pulumi up (refresh and preview are successful) from a CI/CD pipeline: Error: failed to register new resource …… [aws:cloudfront/distribution:Distribution]: Resource monitor is terminating The actual resource is not always the same, or the same type. Running the same commands from my local, but the same code branch, is successful.
    e
    • 2
    • 2
  • q

    quick-hair-25932

    03/16/2022, 9:49 AM
    Hi all! Could anyone help me with a pricing question please? I am responsible for a very small team and we don't have a lot of free funds at this stage. Looking through the pricing page on the Pulumi site, it seems as though, if we are self-hosting the backend/state file, there isn't much need to pay for a teams licence. Is there something that I am missing here?
    e
    • 2
    • 2
  • m

    magnificent-lifeguard-15082

    03/16/2022, 11:32 AM
    What would be the most pain-free way of migrating from a monolithic stack to smaller service-based stacks? Ie. Is there an easy way to migrate state if I am already making use of a parent relationship for the "services" which I want to pull out of a monolithic deployment?
    r
    • 2
    • 2
  • b

    billowy-laptop-45963

    03/16/2022, 1:41 PM
    Anyone have any examples of using aws.ssm.Association with an
    Automation
    document (not Command)? Also is there a way of 'triggering' Automation documents without associating to instance (without dropping to command line) for example to setup a DB or Active Directory users.
    s
    • 2
    • 1
  • m

    melodic-controller-83891

    03/16/2022, 2:27 PM
    Does anyone have an example of GKE private cluster?
  • r

    rough-oyster-77458

    03/16/2022, 2:48 PM
    Hi all, I see Google Cloud Native is recommended for new projects. Does it support more resources vs the old Google Cloud Classic?
    s
    c
    • 3
    • 9
  • d

    damp-holiday-59303

    03/16/2022, 3:21 PM
    My Pulumi stack is in a broken state that I believe should be impossible, not sure what I’m missing. I have a stack with multiple AWS providers for different AWS accounts. I deactivated one of these accounts outside of Pulumi which, as expected, caused
    pulumi up
    and
    pulumi refresh
    to stop working. So I exported the stack, edited the JSON to remove all references to resources or providers in the removed account, and imported the stack. Now,
    pulumi refresh
    works fine, and the stack looks right in the UI and when I export it and look at the JSON. But when I try to run
    pulumi up
    it still complains because it tries to assume a role in the old account to refresh a resource that no longer exists in the stack. The resource referred to in the error message is not present in the UI, using
    pulumi stack --show-urns
    or when exporting and grepping the
    stack.json.
    How can this be? Why is Pulumi still trying to access that resource that it shouldn’t even know exists at this point?
    e
    • 2
    • 5
  • m

    melodic-controller-83891

    03/16/2022, 3:57 PM
    I am trying to create a GKE cluster with the network I created but I keep getting this error even though I have created NAT gateway for the network:
    Network "network" has no route to the default internet gateway. To fix this, add a route with destRange '0.0.0.0/0' and nextHopGateway 'default-internet-gateway'.
    I was able to create a GKE cluster using this network via google console. Does anyone know what the fix is? Thank you
  • s

    sticky-nightfall-24828

    03/16/2022, 4:15 PM
    Hey Output.toString in nodejs sdk still silently fails and returns the error message, for the past 3 years it has said "This function may throw in a future version of @pulumi/pulumi.`;". Is there any reason this hasn't been made to throw, surely this causes countless more headaches than just throwing it. I've seen PRs introducing this same weird behaviour in Python and C# sdks such that its become a pattern.
    e
    • 2
    • 2
  • b

    bright-receptionist-28471

    03/16/2022, 9:11 PM
    Hello! Am I understanding correctly that self-managed backends don't namespace stacks by project? https://github.com/pulumi/pulumi/issues/2522
    l
    e
    • 3
    • 4
  • r

    rough-oyster-77458

    03/16/2022, 9:58 PM
    Hi, AFAIK Google Cloud Native is in pre-release state now. Do you know when it's gonna be ready for production use?
  • b

    bright-needle-80161

    03/16/2022, 10:47 PM
    Hello. Does anyone know how to implement the suggested approach from the error message below in golang ?
    ./main.go:123:3: cannot use arn (type pulumi.StringOutput) as type pulumi.StringMapInput in field value:
        	pulumi.StringOutput does not implement pulumi.StringMapInput (missing ToStringMapOutput method)
    
        error: an unhandled error occurred: program exited with non-zero exit code: 2
    I am trying to create a Kubernetes secret from a secret stored in AWS Secrets Manager. I can lookup the secret in SecretsManager but I don;t know how I can pass the secret data in to the kubernetes secret pulumi module.
    func CreateK8sSecret(ctx *pulumi.Context, arn pulumi.StringOutput, label pulumi.StringMap, provider *kubernetes.Provider) error {
    	found_secret := secretsmanager.LookupSecretOutput(ctx, secretsmanager.LookupSecretOutputArgs{
    		Arn: arn, # Don't know how I could pass the secret data in
    	}, nil)
    
    	ctx.Export("kubernetes_secret", found_secret)
    
    	corev1.NewSecret(ctx, "pulumi-secret", &corev1.SecretArgs{
    		// Data: pulumi.StringMap{"pulumi": pulumi.String("new environment")},
    		Data: arn,
    		Metadata: &metav1.ObjectMetaArgs{
    			Labels: label,
    		},
    	}, pulumi.Provider(provider))
    
    	return nil
    }
    s
    • 2
    • 7
  • a

    ancient-solstice-62300

    03/16/2022, 11:04 PM
    Hey all, I was wondering if someone else got this behaviour. Running pulumi up, the preview shows something different than what the update will actually do. For example the preview: 2022-03-16T07:24:25.3394059Z ~ 7 to update 2022-03-16T07:24:25.3394311Z - 1 to delete 2022-03-16T07:24:25.3394599Z 8 changes. 376 unchanged But the update finishes successfully reporting this: 2022-03-16T07:27:10.8394827Z Resources: 2022-03-16T07:27:10.8395196Z ~ 2 updated 2022-03-16T07:27:10.8395579Z 382 unchanged 2022-03-16T07:27:10.8395722Z 2022-03-16T07:27:10.8395984Z Duration: 2m8s Is this normal?
    l
    • 2
    • 3
  • l

    little-cartoon-10569

    03/17/2022, 1:22 AM
    I'm getting an internal assertion thrown here: https://github.com/pulumi/pulumi/blob/8b516bb05434ca8c6dac94b76a5583e855ffd0b6/sdk/go/common/resource/plugin/provider_plugin.go#L808 (Actually, it's line 807 in the stack trace, but presumably either the URN or ID is empty..) This is in a brand new project/stack. Never been deployed. Any ideas on what I should be looking for?
    e
    • 2
    • 9
  • s

    stale-vase-87890

    03/17/2022, 2:02 PM
    By chance has anyone setup AWS with Okta SSO, and are managing group/policy assignments with Pulumi? In order to assign a Okta Push Group to an AWS account, one has to know the Group ID that AWS created when the group was pushed from Okta. I don't see a way to get that ID with Pulumi and really don't want to have to hard code each group.
    • 1
    • 1
  • f

    fast-easter-23401

    03/17/2022, 3:30 PM
    Hi everybody, Is there a way to change a resource ID without hacking the stack state or bastardizing resources with aliases? If I could manage this using the CLI, that would be great. Many thanks!
    e
    • 2
    • 5
  • b

    bright-diamond-93374

    03/17/2022, 3:53 PM
    Hey all, has anyone had any chance using
    stageVariables
    to define AWS API Gateway integrations? I have been trying to do something like this:
    new Aws.ApiGatewayV2.Integration("lambda", new Aws.ApiGatewayV2.IntegrationArgs
    {
        ApiId = "...",
        IntegrationMethod = "POST",
        IntegrationType = "AWS_PROXY",
        IntegrationUri = "${stageVariables.apiFunc}",
        PayloadFormatVersion = "2.0",
    });
    but pulumi is complaining the
    IntegrationUri
    is not a proper ARN
    r
    • 2
    • 2
  • r

    red-football-97286

    03/17/2022, 4:00 PM
    Is Go 1.18 usable in Pulumi?
    e
    • 2
    • 4
Powered by Linen
Title
r

red-football-97286

03/17/2022, 4:00 PM
Is Go 1.18 usable in Pulumi?
e

echoing-dinner-19531

03/17/2022, 4:30 PM
As in can you build pulumi programs using go 1.18? That should be fine. As in does pulumi use an 1.18 features? No not yet.
r

red-football-97286

03/17/2022, 4:57 PM
@echoing-dinner-19531 Thanks. It was if it used the 1.18 features.
e

echoing-dinner-19531

03/17/2022, 4:58 PM
We do hope to use them, especially generics but it will be some time before that.
r

red-football-97286

03/17/2022, 8:03 PM
That's a shame :(
View count: 2