• Skip to main content

Uly.me

cloud engineer

  • Home
  • About
  • Archives

bash_profile

AWS SDK Load Config

February 14, 2022

Occasionally I was getting this random error when running Terraform.

╷
│ Error: error configuring Terraform AWS Provider: no valid credential sources for Terraform AWS Provider found.
│ 
│ Please see https://registry.terraform.io/providers/hashicorp/aws
│ for more information about providing credentials.
│ 
│ Error: RequestError: send request failed
│ caused by: Post "https://sts.amazonaws.com/": read tcp xx.xx.xx.xx:59422->xx.xx.xx.xx:443: read: connection reset by peer
│ 
│ 
│   with provider["registry.terraform.io/hashicorp/aws"],
│   on main.tf line 10, in provider "aws":
│   10: provider "aws" {

╷ │ Error: error configuring Terraform AWS Provider: no valid credential sources for Terraform AWS Provider found. │ │ Please see https://registry.terraform.io/providers/hashicorp/aws │ for more information about providing credentials. │ │ Error: RequestError: send request failed │ caused by: Post "https://sts.amazonaws.com/": read tcp xx.xx.xx.xx:59422->xx.xx.xx.xx:443: read: connection reset by peer │ │ │ with provider["registry.terraform.io/hashicorp/aws"], │ on main.tf line 10, in provider "aws": │ 10: provider "aws" {

Here’s the fix. Place this in your ~/.bash_profile.

export AWS_SDK_LOAD_CONFIG=1

export AWS_SDK_LOAD_CONFIG=1

This forces Terraform to use both config and credentials file.

Filed Under: Linux Tagged With: aws, awscli, bash_profile, cli, config, credentials, sdk, terraform

Git Bash Path

August 19, 2020

Here’s how to add or edit the PATH in Git Bash. Edit your bash_profile.

vi ~/.bash_profile

vi ~/.bash_profile

Set your path by adding the new path at the end.

PATH="/c/WINDOWS/system32:/c/Users/firstname.lastname/google-cloud-sdk/bin"

PATH="/c/WINDOWS/system32:/c/Users/firstname.lastname/google-cloud-sdk/bin"

The example path listed above is truncated for brevity.

Filed Under: Cloud, Linux Tagged With: add, bash_profile, gcloud, git bash, path

  • Home
  • About
  • Archives

Copyright © 2023