https://pulumi.com logo
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
  • g

    gentle-market-22852

    08/17/2022, 10:01 AM
    However, I do see the need for more
    database: mongodb
    mongoHost: localhost
    nodeEnvironment: "18"
    protocols: http
    can any confirm the exact value of these to run this example.. with above config, pulumi up says
    * Error initializing Docker client: protocol not available
  • g

    gentle-market-22852

    08/17/2022, 10:02 AM
    https://www.pulumi.com/learn/pulumi-fundamentals/configure-and-provision/ this example talks about environment variables
    backendPort: "3000"
    frontendPort: "3001"
    mongoPort: "27017"
  • g

    gentle-market-22852

    08/17/2022, 10:05 AM
    Also, the same example shows source code last line in java as
    return ctx.exports();
    but this method does not seem to exist or this method signature says void some thing wrong with the code shown
    🙌 1
  • g

    gentle-market-22852

    08/17/2022, 10:07 AM
    Also, the description not clear where to put this java code with in this github cloned code https://github.com/pulumi/tutorial-pulumi-fundamentals
  • g

    gentle-market-22852

    08/17/2022, 12:40 PM
    @echoing-dinner-19531 any info on this please
    e
    • 2
    • 3
  • m

    microscopic-piano-27908

    08/17/2022, 6:25 PM
    👋 I’ve been following along with this

    video▾

    and everything is going well except for at the current timestamp. If I run
    pulumi logs
    after making a successful request to to the lambda, I don’t see any logs
  • m

    microscopic-piano-27908

    08/17/2022, 6:26 PM
    ❯ curl $(pulumi stack output url)                                                                   
    hello
    
    ❯ pulumi logs                     
    Collecting logs for stack dev since 2022-08-17T11:25:46.000-06:00.
    And then the logs exits
    l
    • 2
    • 7
  • q

    quaint-pharmacist-79538

    08/18/2022, 1:53 PM
    Hello Pulumi, Im looking for a solution to get my public Ip from Kubernetes ingress ? Something like :
    let service = Service.get("my-release-nginx-ingress")
    let myIp = service.status.loadBalancer.ingress[0].ip
    But : the service "my-release-nginx-ingress" was not created by pulumi, it was already here. Any tips for me ?
    b
    • 2
    • 4
  • m

    microscopic-piano-27908

    08/18/2022, 4:58 PM
    const filesBucket = new aws.s3.Bucket('filesBucket')
    
    const createNewFile = () => {
        new aws.s3.BucketObject(
            'foo.txt', 
            {
                bucket: filesBucket,
                content: ''
            }
        )
    }
    
    const createNewFileSchedule: aws.cloudwatch.EventRuleEventSubscription = aws.cloudwatch.onSchedule(
        "createNewFile",
        "rate(2 minutes)",
        createNewFile
    );
    Is there something I’m doing wrong with the
    createNewFile
    function? I’m not seeing new files show up in the Bucket on AWS
    b
    • 2
    • 1
  • h

    hallowed-father-38428

    08/18/2022, 11:55 PM
    the IaC with Python on AWS presentation was very friendly and easy to follow especially with the Output as JS Promise analogy thanks @bland-continent-32037
    ❤️ 3
    b
    • 2
    • 6
  • s

    sparse-intern-71089

    08/19/2022, 5:56 PM
    This message was deleted.
    b
    h
    • 3
    • 2
  • s

    salmon-sandwich-15994

    08/21/2022, 12:31 AM
    I always get this message when using a template with pulumi up. "error: azure-native:resources:ResourceGroup resource 'resourceGroup' has a problem: missing required property 'location'. Either set it explicitly or configure it with 'pulumi config set azure-native:location <value>'." Steps to reproduce this error: pulumi config set azure-native:location westus2 pulumi up https://github.com/pulumi/examples/tree/master/azure-py-aci What I have tried: I have deleted all of my stacks to start fresh, but it still gives the same error. I have looked at the documentation to make sure I am not missing some key syntax, but everything looks correct. Here is what my command line looks like:
    gitpod /workspace/pulumi/p $ pulumi config set azure-native:location westus2
    Please choose a stack, or create a new one: <create a new stack>
    Please enter your desired stack name.
    To create a stack in an organization, use the format <org-name>/<stack-name> (e.g. `acmecorp/dev`): dev
    Created stack 'dev'
    gitpod /workspace/pulumi/p $ pulumi config set azure-native:location westus2
    gitpod /workspace/pulumi/p $ pulumi up <https://github.com/pulumi/examples/tree/master/azure-py-aci>
    project name: (azure-py-aci) 
    project description: (Creates Azure Container Instance with a public IP) 
    Please enter your desired stack name.
    To create a stack in an organization, use the format <org-name>/<stack-name> (e.g. `acmecorp/dev`).
    stack name: (dev) 
    Created stack 'dev'
    Failed to resolve python version command: fork/exec /tmp/pulumi-up-1211997133/venv/bin/python: no such file or directory
    
    Installing dependencies...
    
    Creating virtual environment...
    Finished creating virtual environment
    Updating pip, setuptools, and wheel in virtual environment...
    Requirement already satisfied: pip in ./venv/lib/python3.8/site-packages (21.1.1)
    Collecting pip
      Using cached pip-22.2.2-py3-none-any.whl (2.0 MB)
    Requirement already satisfied: setuptools in ./venv/lib/python3.8/site-packages (56.0.0)
    Collecting setuptools
      Using cached setuptools-65.1.0-py3-none-any.whl (1.2 MB)
    Collecting wheel
      Using cached wheel-0.37.1-py2.py3-none-any.whl (35 kB)
    Installing collected packages: wheel, setuptools, pip
      Attempting uninstall: setuptools
        Found existing installation: setuptools 56.0.0
        Uninstalling setuptools-56.0.0:
          Successfully uninstalled setuptools-56.0.0
      Attempting uninstall: pip
        Found existing installation: pip 21.1.1
        Uninstalling pip-21.1.1:
          Successfully uninstalled pip-21.1.1
    Successfully installed pip-22.2.2 setuptools-65.1.0 wheel-0.37.1
    Finished updating
    Installing dependencies in virtual environment...
    Collecting pulumi<4.0.0,>=3.5.1
      Using cached pulumi-3.38.0-py2.py3-none-any.whl (166 kB)
    Collecting pulumi-azure-native<2.0.0,>=1.14.0
      Using cached pulumi_azure_native-1.68.2-py3-none-any.whl
    Collecting six~=1.12
      Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
    Collecting pyyaml~=5.3
      Using cached PyYAML-5.4.1-cp38-cp38-manylinux1_x86_64.whl (662 kB)
    Collecting grpcio==1.47
      Using cached grpcio-1.47.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.5 MB)
    Collecting dill~=0.3
      Using cached dill-0.3.5.1-py2.py3-none-any.whl (95 kB)
    Collecting semver~=2.8
      Using cached semver-2.13.0-py2.py3-none-any.whl (12 kB)
    Collecting protobuf~=4.21
      Using cached protobuf-4.21.5-cp37-abi3-manylinux2014_x86_64.whl (408 kB)
    Collecting parver>=0.2.1
      Using cached parver-0.3.1-py2.py3-none-any.whl (14 kB)
    Collecting attrs>=19.2
      Using cached attrs-22.1.0-py2.py3-none-any.whl (58 kB)
    Collecting arpeggio~=1.7
      Using cached Arpeggio-1.10.2-py2.py3-none-any.whl (54 kB)
    Installing collected packages: arpeggio, six, semver, pyyaml, protobuf, dill, attrs, parver, grpcio, pulumi, pulumi-azure-native
    Successfully installed arpeggio-1.10.2 attrs-22.1.0 dill-0.3.5.1 grpcio-1.47.0 parver-0.3.1 protobuf-4.21.5 pulumi-3.38.0 pulumi-azure-native-1.68.2 pyyaml-5.4.1 semver-2.13.0 six-1.16.0
    Finished installing dependencies
    Finished installing dependencies
    
    Previewing update (dev)
    
    View Live: <https://app.pulumi.com/aselunar/azure-py-aci/dev/previews/05e20ed7-f05a-4ec2-a0c4-5f5336cf5ce2>
    
         Type                                     Name              Plan       Info
     +   pulumi:pulumi:Stack                      azure-py-aci-dev  create     
         └─ azure-native:resources:ResourceGroup  resourceGroup                1 error
     
    Diagnostics:
      azure-native:resources:ResourceGroup (resourceGroup):
        error: azure-native:resources:ResourceGroup resource 'resourceGroup' has a problem: missing required property 'location'. Either set it explicitly or configure it with 'pulumi config set azure-native:location <value>'.
    👍 1
    b
    • 2
    • 8
  • w

    wooden-night-90022

    08/22/2022, 3:51 AM
    👋 Hello, team!
  • w

    wooden-night-90022

    08/22/2022, 3:52 AM
    This is driving me bats - I'm attempting to get a vm initialised on proxmox using the Proxmox Virtual Environment (Proxmox VE) package from the registry.
  • w

    wooden-night-90022

    08/22/2022, 4:00 AM
    This is driving me bats - I'm attempting to get a vm initialised on proxmox using the Proxmox Virtual Environment (Proxmox VE) package from the registry.-i don't know whether its a bug or my coding. (and clearly i don't use slack much) The error I get is: proxmoxve:VM:VirtualMachine (vm-1): error: You must specify the virtual environment details in the provider configuration But the debug shows this: I0822 13:38:13.919223 1359098 schema.go:347] Terraform input virtual_environment = []interface {}{map[string]interface {}{"__defaults":[]interface {}{"otp"}, "endpoint":"https://server.fqdn", "insecure":"true", "otp":"", "password":"apassword", "username":"userid"}} I0822 13:38:13.919966 1359098 schema.go:347] Terraform input __defaults = []interface {}{} This seems to work: provider_ve = Provider('proxmoxve', virtual_environment=proxmox.ProviderVirtualEnvironmentArgs( endpoint=os.environ['PROXMOX_VE_ENDPOINT'], insecure=os.environ['PROXMOX_VE_INSECURE'], username=os.environ['PROXMOX_VE_USERNAME'], password=os.environ['PROXMOX_VE_PASSWORD'], ), ), and I create the vm with: vm_1 = proxmox.vm.VirtualMachine("vm-1",provider=provider_ve,args=vm1_conf_args) so preview works and then it fails with the error above. At this point I almost hope its a bug - because then having wasted a lot of time - I might console myself that its not me its the package.
    c
    • 2
    • 14
  • f

    fresh-musician-40418

    08/22/2022, 12:57 PM
    Hello team, Our team just started to use Pulumi Service and we have an organization. Is there a way to generate access token on behalf of that organization? I can only generate my individual personal access token. If there is a way, do I need to be an admin of that organization?
    s
    c
    l
    • 4
    • 19
  • g

    gentle-market-22852

    08/22/2022, 1:19 PM
    Docker example (https://github.com/pulumi/examples/tree/master/docker-ts-multi-container-app)is failing with error: 1 error occurred: * Error initializing Docker client: protocol not available I am running on windows 10 with docker for desktop launched works on wsl2 linux.. can any say how to make it work on windows too
    r
    • 2
    • 3
  • g

    gentle-market-22852

    08/22/2022, 2:08 PM
  • w

    wet-fall-57893

    08/23/2022, 1:57 AM
    Re-ask in this channel. Hey guys would stack reference work if I don’t have an account? Followed format described in this link threw error saying unknown stack
    b
    • 2
    • 1
  • h

    helpful-memory-76476

    08/23/2022, 3:10 PM
    Hi everyone, I am setting up some auto-deployments to azure, I have most of it figured out, but I need to set a property in my SQL Server and I can't find out how (pic attached). I need to set "Networking -> Exceptions: Allow Azure Services and Resources to access this server" to "true".
    h
    • 2
    • 2
  • p

    plain-eve-99442

    08/24/2022, 12:44 PM
    HI Everyone I am not able to install pulumi in mac can any one help me
    c
    • 2
    • 14
  • c

    clever-rose-11123

    08/26/2022, 5:58 AM
    Hi there, does anyone know how to pass fargate a custom role in awsx or how to add permissions to the default role? I'm trying to give it permission to look up a secret
  • f

    fancy-bird-54024

    08/27/2022, 11:05 AM
    Hello team I found
    pulumi new
    has a
    --config stringArray
    option. But it seems not say what
    stringArrary
    should look like. I try
    --config aws:region:us-east-1
    but it complains a error: (my terminal is PowerShell)
    error: could not parse aws:region:us-east-1 as a configuration key (configuration keys should be of the form `<namespace>:<name>`)
    so what it should look like?
    "aws:region:us-east-1"
    or
    aws:region us-east-1
    (will complain too much args) seems both not the correct answer. Thanks~
    b
    b
    • 3
    • 7
  • e

    eager-pilot-22899

    08/29/2022, 2:33 PM
    Hey! I'm trying to do something very basic, just create an EC2 instance with Pulumi. I copied and pasted the example from the docs but they don't work. 😕 Here's my code:
    const vpc = new aws.ec2.Vpc("vpc", {
        cidrBlock: "10.0.0.0/16",
    });
    And here's my error:
    +  pulumi:pulumi:Stack testproject-abc123-dev created 
        aws:ec2:Vpc vpc **failed** 1 error
     
    Diagnostics:
      aws:ec2:Vpc (vpc):
        error: could not validate provider configuration: 1 error occurred:
            * Invalid or unknown key
    Does anyone know what's going on? Thanks!
    b
    • 2
    • 7
  • s

    salmon-motherboard-78006

    08/29/2022, 9:04 PM
    Hi all, Is it possible to move
    ___main___.py
    to a different folder and specify somehow the entry point path in the
    yaml
    file?
    b
    • 2
    • 1
  • a

    average-printer-31589

    08/31/2022, 8:05 AM
    Hello all 👋 , currently pulumi takes up a lot of time to build using docker, is there any CI/CD solution to optimize build times? We are not using github actions or such. Pulumi rebuilds all docker images regardless of the changes we’ve made ,so is there a short/long fix for this? All options are appreciated. I found one issue discussing something on the same lines but can’t see a solution proposed : https://github.com/pulumi/pulumi-cloud/issues/183
    s
    • 2
    • 2
  • b

    boundless-island-39178

    09/01/2022, 2:50 PM
    Hi ! I'm trying to create a new scheduledQueryRule including dimensions. From the docs I can see that the only possible values for "Action" is either AlertingActionArgs or LogToMetricActionArgs. I want to be able to specify the ActionGroup for my Logic App as well as a criteria property to include some dimensions to be sent to my Logic App. Since the Action parameter doesn't allow me to input both an ActionGroup and a Criteria i'm a bit at a lost here. What i'm basically trying to simulate is in the screenshots attached below. Can anyone point me to the right direction on this ? Thanks !
    return new ScheduledQueryRule($"{applicationInsights.Name}Query{alertRuleName}", new ScheduledQueryRuleArgs
                {
                    Action = new AlertingActionArgs
                    {
                        AznsAction = new AzNsActionGroupArgs
                        {
                            ActionGroup = new[]
                            {
                                $"/subscriptions/{subscriptionId}/resourceGroups/{actionResourceGroupName}/providers/microsoft.insights/actiongroups/{actionGroupName}"
                                
                            }
                            
                        },
                        OdataType = "Microsoft.WindowsAzure.Management.Monitoring.Alerts.Models.Microsoft.AppInsights.Nexus.DataContracts.Resources.ScheduledQueryRules.AlertingAction",
                        Severity = AlertSeverity.One,
                        Trigger = new TriggerConditionArgs
                        {
                            Threshold = 1,
                            ThresholdOperator = ConditionalOperator.GreaterThanOrEqual.ToString()
                        }
                    },
                    Enabled = Enabled.True,
                    ResourceGroupName = applicationInsights.ResourceGroup,
                    RuleName = ruleName,
                    Description = $"Query search on : {ruleName} ",
                    Location = applicationInsightsAccessor.GetResourceLocation(applicationInsights),
                    Schedule = new ScheduleArgs
                    {
                        FrequencyInMinutes = 5,
                        TimeWindowInMinutes = 5
                    },
                    Source = new SourceArgs
                    {
                        DataSourceId = applicationInsightsAccessor.GetResourceId(applicationInsights),
                        Query = query,
                        QueryType = QueryType.ResultCount
                    }
     });
  • i

    important-sugar-9877

    09/02/2022, 1:47 PM
    hey all, is there a way to copy files to a vm in rsync style? i only found remote.copyFile so far, that would be a bit cumbersome to use for many files
    s
    g
    a
    • 4
    • 9
  • a

    astonishing-dentist-11149

    09/03/2022, 9:27 PM
    Hello all! Have any of you found a course or a series that you really like that walks through pulumi typescript for micro services? I am coming from pulumi python.
  • t

    thousands-area-40147

    09/05/2022, 2:57 PM
    Hey gang, is there any way to check the existence of a stack before creating a
    new StackReference()
    for it? Asking because the error
    StackReference()
    throws if the stack doesn't exist seems to be uncatchable. This is for Typescript btw, so maybe I should've asked it in #typescript instead 😅
    v
    l
    • 3
    • 8
Powered by Linen
Title
t

thousands-area-40147

09/05/2022, 2:57 PM
Hey gang, is there any way to check the existence of a stack before creating a
new StackReference()
for it? Asking because the error
StackReference()
throws if the stack doesn't exist seems to be uncatchable. This is for Typescript btw, so maybe I should've asked it in #typescript instead 😅
v

victorious-church-57397

09/05/2022, 3:04 PM
might be a bit hacky, but you could use the pulumi
Command
resource to run
pulumi stack ls
and then you could check in the output of that if the stack exists
https://www.pulumi.com/registry/packages/command/
t

thousands-area-40147

09/05/2022, 3:05 PM
Yeah, that was my first hack, but unfortunately it doesn't work with the drift detection we're running in the cloud.
v

victorious-church-57397

09/05/2022, 3:06 PM
ah, i dont think theres a method for listing stacks programatically - you have to use the command afaik. have you looked at the automation api? that might have something in it you can use
t

thousands-area-40147

09/05/2022, 3:08 PM
I'll look around some more, thanks for your input 😄
v

victorious-church-57397

09/05/2022, 3:08 PM
https://www.pulumi.com/docs/guides/automation-api/
The Pulumi Automation API is a programmatic interface for running Pulumi programs without the Pulumi CLI. Conceptually, this can be thought of as encapsulating the functionality of the CLI (pulumi up, pulumi preview, pulumi destroy, pulumi stack init, etc.) but with more flexibility. It is a strongly typed and safe way to use Pulumi in embedded contexts such as web servers without having to shell out to a CLI.
l

limited-rainbow-51650

09/06/2022, 6:29 AM
In code, use the Pulumi Service REST API and you can list all stacks, or get a specific stack. Based on the HTTP return code, I think you have what you need: https://www.pulumi.com/docs/reference/service-rest-api/#get-stack
✅ 1
🙏 1
View count: 6