ec_deployment_extension - Not working
syepes opened this issue · 3 comments
syepes commented
Looks like the resource "ec_deployment_extension" has some kind of issue when downloading the bundle file
Readiness Checklist
- I am running the latest version
- I checked the documentation and found no answer
- I checked to make sure that this issue has not already been filed
- I am reporting the issue to the correct repository (for multi-repository projects)
Expected Behavior
Should download the file directly
Terraform definition
resource "ec_deployment_extension" "this" {
name = "mapper-size"
version = "8.12.0"
extension_type = "bundle"
download_url = "https://artifacts.elastic.co/downloads/elasticsearch-plugins/mapper-size/mapper-size-8.12.0.zip"
}
==================== Start of Request #1 ====================
POST /api/v1/deployments/extensions HTTP/1.1
Host: api.elastic-cloud.com
User-Agent: elastic-terraform-provider/0.9.0 (cloud-sdk-go/3.7.0)
Content-Length: 181
Accept: application/json
Authorization: [REDACTED]
Content-Type: application/json
Accept-Encoding: gzip
{"download_url":"https://artifacts.elastic.co/downloads/elasticsearch-plugins/mapper-size/mapper-size-8.12.0.zip","extension_type":"bundle","name":"mapper-size","version":"8.12.0"}
==================== End of Request #1 ====================
==================== Start of Response #1 ====================
HTTP/1.1 403 Forbidden
Cache-Control: max-age=0, no-cache, no-store, must-revalidate
Connection: keep-alive
Content-Type: application/json
Date: Thu, 25 Jan 2024 21:36:51 GMT
Server: fac/666352e
Strict-Transport-Security: max-age=3600; includeSubDomains
X-Cloud-Error-Codes: root.unauthorized
X-Content-Type-Options: nosniff
X-Download-Options: noopen
X-Frame-Options: SAMEORIGIN
X-Request-Id: 195b7a2cf05bf27d532f45dfe310315d
X-Xss-Protection: 1;mode=block
{"errors":[{"code":"root.unauthorized","message":"The supplied authentication is not authorized to access this resource"}]}
==================== End of Response #1 ====================
Your Environment
- Version used: 0.9.0
- Running against Elastic Cloud SaaS
tobio commented
@syepes This is a Cloud API 403. The API key used in the provider configuration is either invalid, or owned by a user which doesn't have permission to manage deployment extensions.
syepes commented
@tobio That is the issue, I am using the same and correct apikey to deploy my instances already.
Does this require a special API key? I am already using a "Organization owner" key
tobio commented
@syepes can you reach out to support to investigate this one further, either via the Cloud portal or support@elastic.co.