Thread
#python
    s

    steep-lamp-20408

    2 weeks ago
    Hey there, Is anyone using Localstack with Pulumi in Python, and/or pulumi-local? I read this doc which got me pretty excited before I tried since it looked simple enough.: https://docs.localstack.cloud/integrations/pulumi/ However, when running the command
    pulumilocal up
    , I get this non explicit error:
    Do you want to perform this update? yes
    Updating (localstack)
    
    View Live: <https://app.pulumi.com/my-user/myproject-backend/localstack/updates/5>
    
         Type                       Name                             Status                  Info
         pulumi:pulumi:Stack        myproject-backend-localstack     **failed**              1 error; 2 warnings
     +   └─ aws:appsync:GraphQLApi  myproject-localstack-graphqlapi  **creating failed**     1 error 
    
    Diagnostics:
      aws:appsync:GraphQLApi (myproject-localstack-graphqlapi):
        error: 1 error occurred:
            * error creating AppSync GraphQL API: InternalFailure:
            status code: 501, request id: 2DNPS6TTA6YNSW2F783MVI1V6DJZEJ8GJ61G1F4F
    
    pulumi:pulumi:Stack (myproject-backend-localstack):
        warning: provider config warning: Use s3_use_path_style instead.
        warning: provider config warning: Use s3_use_path_style instead.
        error: update failed
    Notes: • The stack works well when
    pulumi up
    on non-local. • The stack consists of AWS resources, including a Appsync GraphQL API • Side question: what are those warnings?
    poke @lively-rain-14200
    m

    millions-furniture-75402

    2 weeks ago
    Not sure if related because we don't use
    pulumilocal
    to utilize localstack, but I will say that our localstack stack YAML has:
    aws:s3ForcePathStyle: 'true'
    s

    steep-lamp-20408

    2 weeks ago
    Thanks @millions-furniture-75402. I already have
    aws:s3ForcePathStyle: 'true'
    in my
    Pulumi.localstack.yaml
    Will also tried without
    pulumi-local
    ...same without
    pulumi-local
    (just switching stack to stack
    localstack
    and doing
    pulumi up
    ) 😪
    m

    millions-furniture-75402

    2 weeks ago
    oh looks like maybe this variable name was updated in the provider? https://github.com/hashicorp/terraform-provider-aws/issues/23026
    Try
    aws:s3UsePathStyle: 'true'
    s

    steep-lamp-20408

    2 weeks ago
    oh looks like maybe this variable name was updated in the provider? https://github.com/hashicorp/terraform-provider-aws/issues/23026
    This is about the warnings, but not the error, right?
    m

    millions-furniture-75402

    2 weeks ago
    right, I assumed the error was related to the warning
    s

    steep-lamp-20408

    2 weeks ago
    Me too, but I’m afraid not
    m

    millions-furniture-75402

    2 weeks ago
    Maybe try a redux version of your declaration and see if it's related to the properties of the AppSync GraphQL API properties?
    s

    steep-lamp-20408

    2 weeks ago
    The error is
    error creating AppSync GraphQL API: InternalFailure:
            status code: 501
    m

    millions-furniture-75402

    2 weeks ago
    localstack is not a perfect 1:1 with AWS, there are gaps, and in our case we have some conditional logic around features/properties not supported by localstack
    s

    steep-lamp-20408

    2 weeks ago
    Yeah I’m afraid AWS Appsync is not working with localstack maybe.
    Do you have Appsync in your stack?
    m

    millions-furniture-75402

    2 weeks ago
    Quite likely, you can get an idea of coverage on the localstack website
    We do not.
    also worth mentioned that localstack pro has more features than the community version, but still not full coverage
    AppSync looks pro-only
    s

    steep-lamp-20408

    2 weeks ago
    Yup, seems Appsync is supposed to work under localstack
    m

    millions-furniture-75402

    2 weeks ago
    Do you have a pro license?
    s

    steep-lamp-20408

    2 weeks ago
    Nope
    Oh it’s for pro indeed
    It was indeed because I wasn’t using pro. Non pro doesn’t have Appsync ability. I tried with a trial API key and it worked. The error message from Pulumi was of course very obscure! Thanks @millions-furniture-75402 for his help