Terraform 405 not allowed

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Terraform 405 not allowed

L0 Member

not sure im doing wrong here but trying to connect using terraform results in a 405 not allowed. 
Here is my TF code 

```
terraform {
required_providers {
prismacloud = {
source = "PaloAltoNetworks/prismacloud"
version = "1.2.11"
}
}
}

provider "prismacloud" {

json_config_file = ".prismacloud_auth.json"
}

resource "prismacloud_account_group" "ba" {
name = "ba-account-group"
description = "created by Terraform"
account_ids = []
}

 

here is my .prismacloud_auth.json

{
    "url": "app2.eu.prismacloud.io",
    "username": "KEY",
    "password": "SECRET_KEY",
    "protocol": "https"
}



and here is the error

2023-03-09T20:42:47.904Z [TRACE] vertex "provider[\"registry.terraform.io/paloaltonetworks/prismacloud\"]": visit complete, with errors
2023-03-09T20:42:47.904Z [TRACE] dag/walk: upstream of "prismacloud_account_group.ba (expand)" errored, so skipping
2023-03-09T20:42:47.904Z [TRACE] dag/walk: upstream of "prismacloud_account_group.gdp (expand)" errored, so skipping
2023-03-09T20:42:47.904Z [TRACE] dag/walk: upstream of "prismacloud_account_group.iagl (expand)" errored, so skipping
2023-03-09T20:42:47.904Z [TRACE] dag/walk: upstream of "provider[\"registry.terraform.io/paloaltonetworks/prismacloud\"] (close)" errored, so skipping
2023-03-09T20:42:47.905Z [TRACE] dag/walk: upstream of "root" errored, so skipping
2023-03-09T20:42:47.905Z [TRACE] LoadSchemas: retrieving schema for provider type "registry.terraform.io/paloaltonetworks/prismacloud"

│ Error: 405 error without the "X-Redlock-Status" header - returned HTML:
│ <html>
│ <head><title>405 Not Allowed</title></head>
│ <body>
│ <center><h1>405 Not Allowed</h1></center>
│ <hr><center>openresty</center>
│ </body>
│ </html>


│ with provider["registry.terraform.io/paloaltonetworks/prismacloud"],
│ on provider.tf line 1, in provider "prismacloud":
│ 1: provider "prismacloud" {


2023-03-09T20:42:47.905Z [TRACE] statemgr.Filesystem: removing lock metadata file .terraform.tfstate.lock.info
2023-03-09T20:42:47.906Z [TRACE] statemgr.Filesystem: unlocked by closing terraform.tfstate
2023-03-09T20:42:47.907Z [DEBUG] provider.stdio: received EOF, stopping recv loop: err="rpc error: code = Unavailable desc = error reading from server: EOF"
2023-03-09T20:42:47.919Z [DEBUG] provider: plugin process exited: path=.terraform/providers/registry.terraform.io/paloaltonetworks/prismacloud/1.2.11/windows_amd64/terraform-provider-prismacloud_v1.2.11.exe pid=5116
2023-03-09T20:42:47.919Z [DEBUG] provider: plugin exited

1 REPLY 1

L1 Bithead

Hello, Can you please modify the code as following and try applying the template again
version = 1.3.1

Delete these 4 lines 
resource "prismacloud_account_group" "ba" {
name = "ba-account-group"
description = "created by Terraform"
account_ids = []
}

https://registry.terraform.io/providers/PaloAltoNetworks/prismacloud/latest/docs

Cloud Security Architect @Prisma Cloud Customer Success
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!