Open arun2205 opened 3 years ago
Having the same issue. It worked before (last tested 2-3 weeks ago).
Mee to, same issue with oss backend
same issue, any updates?
Setting my access and secret keys as system variables in my PC advanced settings fixed the issue for me. Variables must be named ALICLOUD_ACCESS_KEY and ALICLOUD_SECRET_KEY
Hi,
I am trying to create ECS instance using terraform with oss as a backend configuration to store terraform statefile.
Terraform Version
Terraform version: 0.15.4
Terraform Configuration Files
provider "alicloud" { access_key = "${var.access_key}" secret_key = "${var.secret_key}" region = "${var.region}" } terraform { required_providers { alicloud = { source = "aliyun/alicloud" version = "~> 1.123.0" } }
backend "oss" { bucket = "alicloud-dev" prefix = "terraform-state/test" endpoint = "https://oss-cn-shanghai.aliyuncs.com" region = "cn-shanghai" }
}
Debug Output
Initializing the backend... 2021-06-11T17:02:07.429+0800 [DEBUG] Instantiate OSS client using endpoint: "https://oss-cn-shanghai.aliyuncs.com" ╷ │ Error: Failed to get existing workspaces: oss: service returned error: StatusCode=400, ErrorCode=InvalidArgument, ErrorMessage="Authorization header is invalid.", RequestId=60C3268F3BA05A313934DDB7
Expected Behavior
Terraform should intialize and store statefile in oss
Actual Behavior
machine and OS details
os: Ubuntu 20.04 64-bit platform: alibabacloud machine-type: ecs.n1.small CPU & Memory: 1Cores 2 GiB
is there i need to configure anything specifically?