dbt-labs / terraform-provider-dbtcloud

dbt Cloud Terraform Provider
https://registry.terraform.io/providers/dbt-labs/dbtcloud
MIT License
84 stars 19 forks source link

Possibility to create database connection and repository #49

Closed edge7 closed 2 years ago

edge7 commented 2 years ago

Hi,

First of all thanks for the repo, pretty helpful. I am wondering if there is also the possibility to create a database connection and repository. Let me explain:

Looking at your project structure:

type Project struct {
    ID                     *int    `json:"id,omitempty"`
    Name                   string  `json:"name"`
    DbtProjectSubdirectory *string `json:"dbt_project_subdirectory,omitempty"`
    ConnectionID           *int    `json:"connection_id,integer,omitempty"`
    RepositoryID           *int    `json:"repository_id,integer,omitempty"`
    State                  int     `json:"state"`
    AccountID              int     `json:"account_id"`
}

I see that is possible to pass repoID and connectionID, I guess those should be already existing. Any chance to create those through this terraform module?

Thanks for any clarification

GtheSheep commented 2 years ago

Hey! Thanks for checking out this project!

You're right, neither of those exist yet, I prioritised what I was using the provider for.

I'll get credentials/ repositories added to the provider in the next couple of days!

GtheSheep commented 2 years ago

Hey, I've added a basic setup for resources/ data sources for both of these and pre-released under v0.0.76, to be honest I'm probably missing a fair few options as the example values I see are based on my setup (Github + Snowflake), so if you're using something different and need extra params could you please list them here and I'll add? thanks!

edge7 commented 2 years ago

Hey, I've got the same setup, going to try that now and give some feedback. If all is good, I think I am going to close this issue.

Thanks

edge7 commented 2 years ago

Hi, I've tested the 'create repo' capability. The terraform module works, but it looks like the API do not allow us to set some parameters such as 'git_clone_strategy' or 'credentials_id' which are important in my case. My set up is Snowflake + Gitlab Have you been able to make it work for your case?

GtheSheep commented 2 years ago

Ahh my setup was Github not Gitlab, apologies, will add that too 👌

GtheSheep commented 2 years ago

58

github-actions[bot] commented 2 years ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 2 years ago

This issue was closed because it has been inactive for 7 days since being marked as stale.

github-actions[bot] commented 2 years ago

This issue was closed because it has been inactive for 7 days since being marked as stale.