pulumi-awsx icon indicating copy to clipboard operation
pulumi-awsx copied to clipboard

AWS region configuration issue - Fargate task defintion log group region

Open ygyg70 opened this issue 2 years ago • 3 comments

What happened?

I was following this tutorial: https://github.com/pulumi/examples/tree/master/aws-ts-containers, using an AWS profile. In my ~.aws folder there is a credentials file and configuration file with a region defined for the profile. Creation of Fargate service failed with timeout, root cause was failure of the task to execute as the log group region was "null" Issue resolved once region was configured in Pulumi yaml file.

Expected Behavior

Either use region configured for the aws profile, or report an error.

Steps to reproduce

  • Using AWS CLI, create a profile, configure credentials and a region for the profile
  • Follow the tutorial https://github.com/pulumi/examples/tree/master/aws-ts-containers
  • Do not configure region in Pulumi yaml
  • Run pulumi up

Output of pulumi about

CLI
Version 3.79.0 Go Version go1.21.0 Go Compiler gc

Plugins NAME VERSION aws 5.42.0 aws-native 0.8.0 awsx 1.0.5 docker 3.6.1 nodejs unknown

Host
OS darwin Version 13.5.1 Arch arm64

This project is written in nodejs: executable='/usr/local/bin/node' version='v18.13.0'

Current Stack: organization/observability-playground/observability-playground-1

Found no resources associated with observability-playground-1

Found no pending operations associated with observability-playground-1

Backend
Name MacBook-Air-2.localdomain URL file://./data User *** Organizations

Dependencies: NAME VERSION @pulumi/aws-native 0.8.0 @pulumi/awsx 1.0.5 @pulumi/pulumi 3.79.0 @types/node 16.18.46

Pulumi locates its logs in /var/folders/mx/64p_g9kx79n58s0pm8718y3m0000gn/T/ by default

Additional context

No response

Contributing

Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

ygyg70 avatar Aug 31 '23 20:08 ygyg70

Hey. Thanks for filing this. I'm glad you have a workaround. This appears to potentially be an issue with the pulumi aws provider so I'll transfer your issue there and they should be able to better help you.

dixler avatar Sep 01 '23 21:09 dixler

I was able to reproduce this issue locally, thank you @ygyg70 for the detailed description.

It's definitely an issue in our awsx implementation, not in the provider itself, so I will move the issue again. It looks like it's about the way we retrieve the default region here, or rather about the implementation of the getRegion function in utils.

mikhailshilkov avatar Sep 06 '23 14:09 mikhailshilkov