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

Alloydb CRR Promote Secondary Cluster #6589

Conversation

modular-magician
Copy link
Collaborator

To Promote a Secondary Cluster, perform the following 2 changes in the secondary cluster config.

  1. Modify cluster_type = "PRIMARY"
  2. Remove the entire secondary_config field from the config 

Before

resource "google_alloydb_cluster" "secondary" {
  <required-fields> = <value>
  <other-fields> = <value>

  cluster_type = "SECONDARY"
  secondary_config {
    primary_cluster_name = google_alloydb_cluster.primary.name
  }
}

After

resource "google_alloydb_cluster" "secondary" {
  <required-fields> = <value>
  <other-fields> = <value>

  cluster_type = "PRIMARY"
}

After promotion the secondary cluster becomes an independent primary cluster.

Release Note Template for Downstream PRs (will be copied)

alloydb: added support for promotion for `SECONDARY` `google_alloydb_cluster` resources

Derived from GoogleCloudPlatform/magic-modules#9271

Co-authored-by: Riley Karson <[email protected]>
Co-authored-by: Shubham Sahu <[email protected]>
[upstream:e6651ccd68f469385bc0004067c93ca5f773848d]

Signed-off-by: Modular Magician <[email protected]>
@modular-magician modular-magician merged commit 2ef2f6d into hashicorp:main Oct 31, 2023
@modular-magician modular-magician deleted the downstream-pr-e6651ccd68f469385bc0004067c93ca5f773848d branch November 16, 2024 03:42
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.

1 participant