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
getting-started
  • b

    bitter-france-47214

    06/14/2022, 9:57 PM
    Hey all! Situation I defined a
    apigateway.RestAPI
    using OpenAPI. That worked fine so far! Though, there is not integration with the endpoint yet. Question How do I define an event handler for an endpoint defined with OpenAPI to trigger a certain lambda (or how to setup what is shown on the screenshot with pulumi and OpenAPI 3.0)? Setup I am using pulumi with TypeScript. I'd appreciate any help and thanks in advance!!
  • s

    sticky-barista-20144

    06/15/2022, 6:50 PM
    Hi. I'm wondering what's the difference between AWS S3 bucketv2 and bucket resources? Which one should I use?
    l
    • 2
    • 1
  • w

    witty-vegetable-61961

    06/16/2022, 7:02 PM
    Hi all, I wrote a bit of code in my c# pulumi program to execute a console app on apply of a variable (To get the variable into another system). However, I noticed that on a preview, this code executes (understandably, as its in the flow). How can I stop this so that the method is only called on an apply?
    l
    • 2
    • 20
  • s

    salmon-fireman-44748

    06/17/2022, 12:19 AM
    Hey folks, just landing in the pulumi realm where I'd like to test it against some use cases I have with Cluster API and running kubernetes clusters on GCP - is there any existing providers for cluster-api available or any existing examples with this integration?
    v
    • 2
    • 1
  • w

    witty-vegetable-61961

    06/17/2022, 1:05 PM
    hi all, how can I remove all the state from a stack? I want to start again but don't want to delete by each urn.
    c
    • 2
    • 1
  • i

    incalculable-monkey-35668

    06/19/2022, 3:59 AM
    Hi all, I am thinking of installing pulumi-mysql. https://github.com/pulumi/pulumi-mysql I want to manage MySQL user permissions, but I don’t seem to be able to execute Grant statements at the column level.Is there a better way to use Pulumi and execute column level Grant statements?I would like to manage the following query using Pulumi.
    GRANT SELECT (col1), INSERT (col1,col2) ON mydb.mytbl TO 'someuser'@'somehost';
    n
    b
    • 3
    • 5
  • b

    brave-belgium-54530

    06/20/2022, 2:35 PM
    Hi all, I’m trying to assign my RDS instance with a final snapshot containing the actual ID of the instance (which is dynamic and determine by Pulumi, and I want to keep it that way) I couldn’t find anything in the SDK enable me to update the instance’s final snapshot ID after declaring the new rds instance I imagine something like
    db.apply(x => db.set({finaleSnapshotId: `prefix….${x.id}})
    Does anyone here have an experience with that? Thanks 🙂
    l
    • 2
    • 3
  • s

    stale-iron-26898

    06/20/2022, 4:13 PM
    Hi all, I have simple use-case but it become harder 😞 I use RandomPassword to generate password and save it into variable
    user_password = RandomPassword().result
    the variable ‘user_password’ I sent to my dynamic resource which only create a query with the ‘user_password’ inside (Eventually is a string ) the problem is that the value is the Object itself
    <pulumi.output.Output at 0x7ffe81ffe6d0>
    is there a way to export the value i get from randomPassword into a string in run time? 😢 Thanks!
    l
    • 2
    • 4
  • b

    breezy-glass-7721

    06/20/2022, 6:26 PM
    Hi All, This product is new to me. It might be a simple question for you but I would really apricate for your answers. We use pulumi for GCP and BQ service for a product. My question is that: if I have a table in Bigquery with data, can i add new columns to this tables without data deletion in the table? (I couldn’t find or missed good examples for it in documentation.)
  • w

    witty-vegetable-61961

    06/20/2022, 8:41 PM
    when you pass in a func to an apply method, is it executed async?
    b
    • 2
    • 5
  • m

    magnificent-helicopter-3467

    06/21/2022, 6:06 AM
    Hi all, I have a
    Pulumi.dev.yaml
    of the following form:
    config:
      gcp-go-gke:data:
        cluster:
          initialNodeCount: 2
          machineType: n1-standard-2
          name: my-cluster
        registry:
          appLabel: my-proj
          deployment:
            containers:
            - image: us-central1-docker.pkg.dev/my-gcloud-proj/my-gcloud-repo/my-image:0.1.0
              name: my-image
            name: my-deployment
            replicas: 1
          namespace:
            metadata:
              name: namespace-meta
            name: my-namespace
          service:
            name: my-service
            port: 80
            serviceType: LoadBalancer
            targetPort: 8080
      gcp:project: my-proj
      gcp:zone: us-west1-a
    In
    main.go
    , I have the following code:
    type Data struct {
    	cluster  Cluster
    	registry Registry
    }
    
    type Cluster struct {
    	initialNodeCount int
    	machineType      string
    	name             string
    }
    type Registry struct {
    	appLabel   string
    	deployment Deployment
    	namespace  Namespace
    	service    Service
    }
    
    type Deployment struct {
    	containers []Container
    	name       string
    	replicas   int
    }
    
    type Namespace struct {
    	metadata Metadata
    	name     string
    }
    
    type Service struct {
    	name        string
    	port        int
    	targetPort  int
    	serviceType string
    }
    
    type Container struct {
    	image string
    	name  string
    }
    
    type Metadata struct {
    	name string
    }
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    
    		var d Data
    		cfg := config.New(ctx, "")
    		cfg.RequireObject("data", &d)
    
    		engineVersions, err := container.GetEngineVersions(ctx, &container.GetEngineVersionsArgs{})
    		if err != nil {
    			return err
    		}
    		masterVersion := engineVersions.LatestMasterVersion
    
    		cluster, err := container.NewCluster(ctx, d.cluster.name, &container.ClusterArgs{
                ...
            }
    The
    cfg.RequireObject
    call does not panic, but
    d.cluster.name
    resolves to
    ""
    . I’m using this doc as a reference to read structured configuration. Any tips for troubleshooting why the config is not read properly? I used verbose logging (
    pulumi up --logtostderr --logflow -v=9 2> out.txt
    ) but didn’t find anything useful in the logs. Thanks in advance for your help/guidance! 🙂
    e
    • 2
    • 8
  • f

    flat-ambulance-51692

    06/21/2022, 9:27 PM
    Hello all 🙂
  • f

    flat-ambulance-51692

    06/21/2022, 9:33 PM
    Needed to spin up a new AWS environment so thought it was the perfect opportunity to take Pulumi for a test drive. Unfortunately, I seem to have fallen over on the first step!! I'm trying to create a vpc using the code block in the docs (below)
    using System.Collections.Immutable;
    using Pulumi;
    using Pulumi.Awsx.Ec2.Inputs;
    using Ec2 = Pulumi.Awsx.Ec2;
    
    class MyStack : Stack
    {
        public MyStack()
        {
            var vpc = new Ec2.Vpc("custom", new Ec2.VpcArgs
            {
                SubnetSpecs =
                {
                    new SubnetSpecArgs
                    {
                        Type = Ec2.SubnetType.Public,
                        CidrMask = 22,
                    },
                    new SubnetSpecArgs
                    {
                        Type = Ec2.SubnetType.Private,
                        CidrMask = 20,
                    }
                }
            });
    
            this.VpcId = vpc.VpcId;
            this.PublicSubnetIds = vpc.PublicSubnetIds;
            this.PrivateSubnetIds = vpc.PrivateSubnetIds;
        }
    
        [Output] public Output<ImmutableArray<string>> PrivateSubnetIds { get; private set; }
        [Output] public Output<ImmutableArray<string>> PublicSubnetIds { get; private set; }
        [Output] public Output<string> VpcId { get; set; }
    }
    
    class Program
    {
        static Task<int> Main(string[] args) => Deployment.RunAsync<MyStack>();
    }
    However, having some issues resolving dependencies (see attached image). I've included the packages window so you can see the versions. Judging by the
    using
    statements this example code seems out of date?
    b
    • 2
    • 4
  • i

    incalculable-thailand-44404

    06/22/2022, 7:31 PM
    I am trying out DataDog with AWS EKS. I basically want to send logs and metrics from my Kotlin application deployed on aws EKS to datadog. Has anyone done this before? I see datadog provides helm charts which I can probably use with the Pulumi's helmservice api. I was able to get datadog working on my mac and see the logs and metrics on their portal using the mac datadog agent.
    • 1
    • 1
  • b

    breezy-architect-90539

    06/23/2022, 7:11 AM
    Hi Team, I have just started working on the Pulumi and need your guidance. I have to delete few unused static public IP addresses/assignments and they have not exist on the pulumi state file. When I have checked the azure portal that resource json shows me that its attached with tags "source": "pulumi-XXXX" . so If I remove the resource directly from the azure portal then pulumi preview complaint about that resources. What is the best practice I have to use in this scenario. Thanks in advance for the help!!
    l
    • 2
    • 5
  • e

    early-morning-93703

    06/23/2022, 9:01 AM
    Morning guys. I have question about Pulumi in azure-native. In this config:
    import * as pulumi from "@pulumi/pulumi";
    import * as azure_native from "@pulumi/azure-native";
    
    const database = new azure_native.sql.Database("database", {
        databaseName: "testdb",
        location: "southeastasia",
        requestedBackupStorageRedundancy: "Zone",
        resourceGroupName: "Default-SQL-SouthEastAsia",
        serverName: "testsvr",
    });
    Which values of
    requestedBackupStorageRedundancy
    can be use in this config? I can't find any document mention about which value can be use here. Thanks.
  • a

    ancient-solstice-53934

    06/23/2022, 12:24 PM
    Hi Everyone, Is there any way to enable Synapse Link in Azure Cosmos DB containers using Pulumi?
  • e

    elegant-pillow-72893

    06/23/2022, 7:19 PM
    Hello guys, good afternoon! I’m trying to get the primary_access_key from a storage account that was created with azure_native but I’m completely lost. I tried to use the “list_storage_account” to see it but it returns the entire output and I don’t know how to access only to the primary key value since it can’t be accessed through an index. Anybody knows how to access to the primary_access_key from that azure_native storage account?
    Note:
    This is the output I get from list_storage_account
    
    Outputs:
      + name    : {
          + keys: [
          +     [0]: {
                  + creation_time: "2021-08-06T00:13:40.4886860Z"
                  + key_name     : "key1"
                  + permissions  : "FULL"
                  + value        : "xxxxxxxxxxxxx"
                }
          +     [1]: {
                  + creation_time: "2021-08-06T00:13:40.4886860Z"
                  + key_name     : "key2"
                  + permissions  : "FULL"
                  + value        : "xxxxxxxxxxxxxxx"
                }
            ]
        }
    b
    • 2
    • 13
  • s

    silly-scientist-20604

    06/23/2022, 7:49 PM
    Can I specify the pulumi organization in
    Pulumi.yaml
    , in order to prevent accidental resource instantiation into an incorrect Pulumi org? For a consultant who manages Pulumi projects for several customers with separate Pulumi organizations, but all under his/her single email address, it seems unreasonably precarious to rely on correctly setting environment variables before running Pulumi commands.
    b
    • 2
    • 1
  • i

    icy-pilot-31118

    06/23/2022, 7:50 PM
    How does pulumi discover resources? For instance, if I have variable
    deployment = [kubernetes.Deployment(), kubernetes.Deployment()]
    will Pulumi deploy both of the deployments? Do I even need to specify a variable? Will
    Deployment()
    work?
    b
    • 2
    • 3
  • p

    prehistoric-translator-89978

    06/23/2022, 10:22 PM
    I'm looking at how to organize projects/stacks with self managed backend. In the docu, the following structure is proposed:
    ├── infrastructure
    │   ├── index.ts
    │   ├── Pulumi.yaml
    │   ├── Pulumi.dev.yaml
    │   ├── Pulumi.staging.yaml
    │   └── Pulumi.prod.yaml
    ├── myApp
    │   ├── index.ts
    │   ├── Pulumi.yaml
    │   ├── Pulumi.dev.yaml
    │   ├── Pulumi.staging.yaml
    │   └── Pulumi.prod.yaml
    └── ...
    So we use infrastructure to create a vpc and other things in AWS... Now, for some reason, myApp needs to get a hold of the vpcid output from infrastructure... How would I go about that?
    b
    • 2
    • 4
  • l

    loud-carpenter-77875

    06/24/2022, 10:14 AM
    i am very new to pulumi and want to try pulumi-kubernets expriment tried with quickproject and end up with this issue not sure how i can solve this [3:43 PM] pulumi😛ulumi:Stack (quickproject-dev): Traceback (most recent call last): File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 49, in run_pulumi_func func() File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 126, in <lambda> await run_pulumi_func(lambda: Stack(func)) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 143, in init super().__init__("pulumi😛ulumi:Stack", name, None, None) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/resource.py", line 1117, in init Resource.__init__(self, t, name, False, props, opts, remote, False) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/resource.py", line 941, in init register_resource( File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/runtime/resource.py", line 486, in register_resource log.debug( File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/log.py", line 45, in debug _log(engine, engine_pb2.DEBUG, msg, resource, stream_id, ephemeral) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/log.py", line 144, in _log engine.Log(req) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/grpc/_channel.py", line 946, in call return _end_unary_response_blocking(state, call, False, None) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/grpc/_channel.py", line 849, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses" debug_error_string = "{"created":"@1656093959.919937667","description":"Failed to pick subchannel","file":"src/core/ext/filters/client_channel/client_channel.cc","file_line":3260,"referenced_errors":[{"created":"@1656093959.919937322","description":"failed to connect to all addresses","file":"src/core/lib/transport/error_utils.cc","file_line":167,"grpc_status":14}]}" > During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/jagrat/.pulumi/bin/pulumi-language-python-exec", line 107, in <module> loop.run_until_complete(coro) File "/usr/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete return future.result() File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 126, in run_in_stack await run_pulumi_func(lambda: Stack(func)) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 51, in run_pulumi_func await wait_for_rpcs() File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 58, in wait_for_rpcs log.debug("Waiting for outstanding RPCs to complete") File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/log.py", line 45, in debug _log(engine, engine_pb2.DEBUG, msg, resource, stream_id, ephemeral) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/log.py", line 144, in _log engine.Log(req) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/grpc/_channel.py", line 946, in call return _end_unary_response_blocking(state, call, False, None) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/grpc/_channel.py", line 849, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses" debug_error_string = "{"created":"@1656093959.920037994","description":"Failed to pick subchannel","file":"src/core/ext/filters/client_channel/client_channel.cc","file_line":3260,"referenced_errors":[{"created":"@1656093959.920037724","description":"failed to connect to all addresses","file":"src/core/lib/transport/error_utils.cc","file_line":167,"grpc_status":14}]}" > During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/jagrat/.pulumi/bin/pulumi-language-python-exec", line 112, in <module> pulumi.log.error("Program failed with an unhandled exception:") File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/log.py", line 109, in error _log(engine, engine_pb2.ERROR, msg, resource, stream_id, ephemeral) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/pulumi/log.py", line 144, in _log engine.Log(req) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/grpc/_channel.py", line 946, in call return _end_unary_response_blocking(state, call, False, None) File "/home/jagrat/quickstart/venv/lib/python3.8/site-packages/grpc/_channel.py", line 849, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses" debug_error_string = "{"created":"@1656093959.920126045","description":"Failed to pick subchannel","file":"src/core/ext/filters/client_channel/client_channel.cc","file_line":3260,"referenced_errors":[{"created":"@1656093959.920125791","description":"failed to connect to all addresses","file":"src/core/lib/transport/error_utils.cc","file_line":167,"grpc_status":14}]}" > error: an unhandled error occurred: Program exited with non-zero exit code: 1
    b
    a
    • 3
    • 6
  • h

    helpful-animal-2280

    06/24/2022, 10:32 AM
    Hi! 🙂 I'm completely new to Pulumi - I'm trying to create a CD setup that goes dockerhub -> AWS cluster, then be able to view the container running. I've got the automatic push to dockerhub going okay, and I have it creating some resources in AWS including a running ECS, but the cluster doesn't have my docker image in it. I think I'm passing it over incorrectly. The project is here: https://github.com/Dogsocks/pulumi-demo it has a Pulumi github action which shows me a few errors, but nothing that leaps out. I think I'm probably just not passing the right image variable at some point in the main.py...
    b
    • 2
    • 3
  • i

    incalculable-thailand-44404

    06/27/2022, 8:32 PM
    Hi Folks, I am trying to do a deployment using Pulumi on AWS EKS. Seeing this error :
    error: configured Kubernetes cluster is unreachable: unable to load schema information from the API server: the server has asked for the client to provide credentials
    . Any idea?
    w
    • 2
    • 1
  • p

    polite-window-12946

    06/27/2022, 9:32 PM
    Any thoughts? Please let me know if there's a better channel for this thread! Thanks in advance.
  • s

    stale-actor-16546

    06/29/2022, 9:07 AM
    Hi Im trying to manage Akamai properties from pulumi. Im able to create new properties but i cannot update them after creation. I always get the error "CreateFromVersion: cannot be blank". I cant find any references in the documents to provide this field. Any help would be really appreciated. TIA.
    pulumi_test1 = akamai.Property("pulumi-test1",
        contract_id="ctr_G-XXXXXXX",
        group_id="grp_000000",
        hostnames=[akamai.PropertyHostnameArgs(
            cert_provisioning_type="CPS_MANAGED",
            cert_statuses=[akamai.PropertyHostnameCertStatusArgs()],
            cname_from="<http://cdn1.example.net|cdn1.example.net>",
            cname_to="<http://cdn1.example.net.edgesuite.net|cdn1.example.net.edgesuite.net>",
            cname_type="EDGE_HOSTNAME",
        )],
        name="pulumi-test1",
        product_id="prd_Fresca",
        rule_format="latest",
        rules=json.dumps(rules),
        opts=pulumi.ResourceOptions(protect=True)
    )
    b
    • 2
    • 1
  • f

    few-toddler-19603

    06/30/2022, 7:44 PM
    Ok, weird pulumi issue, if I try to run a second pulimi task (action? idk the specific vocabulary but if I run pulumi.Run() a second time) it runs through most of it well but at the end errors with
    error: Duplicate resource URN 'urn:pulumi:masterapi::masterapi::pulumi:pulumi:Stack::masterapi-masterapi'; try giving it a unique name
    which, after hours of troubleshooting, I realised was NOT a duplicate resource I made in equinix (my provider) but something in pulumi trying to make a second stack so I ask, why is pulumi trying to make the stack? and how can I tell it not to
    b
    b
    • 3
    • 27
  • s

    square-train-78639

    07/01/2022, 6:47 AM
    Hi Folks, I am getting hands on Pulumi, and had few questions(for migrating from Terrafrom to Pulumi) What is the equivalent of Terraform
    source
    parameter in Pulumi ? We need to solve a use case where in Different versions of Pulumi resource(s) need to be executed in parallel on the same instance
    e
    • 2
    • 1
  • h

    helpful-animal-74538

    07/01/2022, 12:45 PM
    Anyone know how I can get a reference to a resource created in another stack? I have the resource name as an output (in this case an Azure Native SQL Server). The Azure Native SQL package exposes a
    getServer
    method but this returns a
    GetServerResult
    which does not extend
    Resource
    so cannot be passed to the parent property of another resource - as opposed to the
    Server
    type which you get if you create one in the same flow.
    • 1
    • 2
  • c

    careful-secretary-79148

    07/02/2022, 11:08 AM
    Good morning All I'm new to Pulumi and trying to set up a project on AWS. I thought the latest upgrade would solve the problem after reporting it, but it still remains the same. I feel that when a person installs a new application, all dependency issues must be resolved so that you can use it without having to try figure it out by your own. Maybe someone can help me with the issue as per the attached report. Thanks
    b
    e
    m
    • 4
    • 3
Powered by Linen
Title
c

careful-secretary-79148

07/02/2022, 11:08 AM
Good morning All I'm new to Pulumi and trying to set up a project on AWS. I thought the latest upgrade would solve the problem after reporting it, but it still remains the same. I feel that when a person installs a new application, all dependency issues must be resolved so that you can use it without having to try figure it out by your own. Maybe someone can help me with the issue as per the attached report. Thanks
b

better-umbrella-26052

07/02/2022, 2:14 PM
How about trying the
python -m pip ...
command exactly as it appears when you try to run
pulumi up
. Let's see if there is an error for that?
e

echoing-dinner-19531

07/03/2022, 10:18 AM
I feel that when a person installs a new application, all dependency issues must be resolved so that you can use it without having to try figure it out by your own
We expect users to understand the language they are using. If your using python you need python installed, pulumi can not be responsible for resolving all dependencies of all the runtimes there's just too many combinations and edge cases here. As Kevin says try and run the python command directly and once that works try and run pulumi again.
m

mammoth-salesclerk-61945

07/09/2022, 4:40 PM
We also support yaml which is pretty comfortable to use and avoids dependency issues
View count: 5