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

Feature Request: Separate TF Resource for managing databases of a DBaaS instance #136

Open
tstrohmeier opened this issue Dec 12, 2021 · 13 comments

Comments

@tstrohmeier
Copy link

tstrohmeier commented Dec 12, 2021

Hello,

It would be nice to have different resources for database instances and the databases itself.
This would allow us to manage also the databases with Terraform directly.

Example:

locals {
  zone = "ch-dk-2"
}

resource "exoscale_database_instance" "pg_prod" {
  zone = local.zone
  name = "pg-prod"
  type = "pg"
  plan = "startup-4"

  maintenance_dow  = "sunday"
  maintenance_time = "23:00:00"

  termination_protection = true

  pg {
    version = "13"
    backup_schedule = "04:00"
  }
}

resource "exoscale_database" "my_database" {
    database_instance = exoscale_database_instance.pg_prod
    database_name = "<DATABASE_NAME>"
}

Links from other projects:

@tstrohmeier tstrohmeier changed the title Feature Request: DbaaS - Database & Instance Resource Feature Request: Separate TF Resource for managing Databases of a DBaaS Instance Dec 12, 2021
@tstrohmeier tstrohmeier changed the title Feature Request: Separate TF Resource for managing Databases of a DBaaS Instance Feature Request: Separate TF Resource for managing databases of a DBaaS instance Dec 12, 2021
@retrack
Copy link
Member

retrack commented Dec 15, 2021

Thanks for the suggestion, we will take it in consideration in our planning and also welcome PRs as well.

@tstrohmeier
Copy link
Author

@retrack What is the status on this feature request?

@smangelkramer
Copy link

@retrack Any updates on this?

@SebiSpace
Copy link

@retrack Hi, this issue is now open since more than a year and you said you would take it into consideration, did you already have a look at it?

@llambiel
Copy link
Member

llambiel commented Mar 7, 2023

@retrack Hi, this issue is now open since more than a year and you said you would take it into consideration, did you already have a look at it?

Hi @SebiSpace thanks for the heads-up.

It's still something we are considering, however it's not on top of the priority list at the moment. Unfortunately we don't have a more concrete timeline to share right now but will do once we have.

@tstrohmeier
Copy link
Author

tstrohmeier commented Mar 14, 2023

It seams like aiven (the provider used by Exoscale) is already offering this:
https://registry.terraform.io/providers/aiven/aiven/latest/docs/resources/pg and https://registry.terraform.io/providers/aiven/aiven/latest/docs/resources/pg_database

@llambiel So I guess the API from aiven is available and could be used in a Exoscale TF resource?

@llambiel
Copy link
Member

It seams like aiven (the provider used by Exoscale) is already offering this: https://registry.terraform.io/providers/aiven/aiven/latest/docs/resources/pg and https://registry.terraform.io/providers/aiven/aiven/latest/docs/resources/pg_database

@llambiel So I guess the API from aiven is available and could be used in a TF resource?

You cannot use the Aiven API in direct to manage Exoscale DBaaS resources. If you do so you'll have to setup an account with them. You won't be able to deploy the resources on top of Exoscale that way.

@tstrohmeier
Copy link
Author

@llambiel Yes I know. I mean with "available" that aiven has implemented the API on there side and that it should be possible for Exoscale to implement this API in a reasonable time?

I mean this ticket is open for over one year now.

@llambiel
Copy link
Member

llambiel commented Apr 2, 2023

@tstrohmeier Actually support of this feature requires more than just the Terraform implementation. Some prior work on our API has to be made before we could start with the Terraform implementation. Such work has been added in the pipe. We'll revert back to you once we have an update on this front.

@tstrohmeier
Copy link
Author

@llambiel Ok I see. Can you please keep us here in the ticket updated about the progress?

@simisoft-exo
Copy link
Contributor

@tstrohmeier We have started work to enable this feature in the API

@tstrohmeier
Copy link
Author

@simisoft-exo This sounds good! What is the process on it?

@simisoft-exo
Copy link
Contributor

@simisoft-exo This sounds good! What is the process on it?

The feature is available in our API.
cc: @ste-m @kobajagi @jessicatoscani @llambiel

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

No branches or pull requests

6 participants