Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please Provide Solution to Certificate Authority parameter to google_gke #18

Closed
barywhyte opened this issue May 24, 2021 · 2 comments
Closed

Comments

@barywhyte
Copy link

Hi,

I am using strongDM terraform provider version 1.0.20 with terraform version 0.11.15. I have the plugin downloaded and working fine with terraform version 0.11.15

Here is my code:

terraform {
  required_version = "0.11.15"

provider "sdm" { 
    #source = "strongdm/sdm" 
    version = "v1.0.20"       
}

resource "sdm_resource" "dear_s" {
    postgres {
        name =  "name"
        hostname        = "hostname.net"
        database         = "db-name"
        username        = "username"
        password        = "password"
        port                 = 2342
    }
}

resource "sdm_resource" "dear_b" {
    postgres {
         name            =  "name"
        hostname     = "hostname-2.net"
        database      = "db-name-2"
        username     = "username-2"
        password     = "password-2"
        port              = 2342
    }
}

resource "sdm_resource" "gke_cluster" {
    google_gke {
        name                               =  "cluster-name"
        endpoint                         =  "10.88.88.88"
        certificate_authority      =  "${file(./gke_cert_auth.crt)}"
        service_account_key    =  "${file(./account.json)}"
        
       
    }
}

terraform init
terraform apply

The first two resources were successfully created in strongDM UI but the last time failed to create and output the following error:

Error: Error applying plan:

1 error occurred:
        * sdm_resource.gke_cluster: cannot create Resource: error validating datasource: invalid operation: cannot validate ca cert: invalid cert block pem data

The strange thing is that I can do this successfully on strongDM UI with the same certificate authority credential.

What am I doing wrong here?

@sdm-keller
Copy link

Hi Seun,

We've gone ahead and generated a support ticket on your behalf where we can better assist you via our standard support channels.

I'll go ahead and close this github issue.

Thanks!

Dan Keller
strongDM Support

@barywhyte
Copy link
Author

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants