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

databases: Add backup-restore functionality to db create #970

Merged
merged 7 commits into from
Apr 19, 2023

Conversation

danaelhe
Copy link
Member

@danaelhe danaelhe commented Apr 7, 2023

Addresses #968

Adding API parity of create a new database cluster based on a backup of an existing cluster:

resource "digitalocean_database_cluster" "foobar" {
	name       = "%s"
	engine     = "pg"
	version    = "11"
	size       = "db-s-1vcpu-2gb"
	region     = "nyc1"
	node_count = 1
	tags       = ["production"]
  }
resource "digitalocean_database_cluster" "foobar_backup" {
	name       = "%s"
	engine     = "pg"
	version    = "11"
	size       = "db-s-1vcpu-2gb"
	region     = "nyc1"
	node_count = 1
	tags       = ["production"]
	
	backup_restore {
	  database_name  = "%s"
	}
	depends_on = [
		digitalocean_database_cluster.foobar
	  ]
  }

APICLI-2018

@danaelhe danaelhe requested a review from a team April 7, 2023 02:57
Copy link
Member

@andrewsomething andrewsomething left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! I left one comment inline re: the CheckDestroy piece and it needs a merge from main, but just about good to go.

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

Successfully merging this pull request may close these issues.

None yet

2 participants