Skip to content

Commit

Permalink
Added Cloud SQL user example (#5996) (#11634)
Browse files Browse the repository at this point in the history
* Added Cloud SQL user example

* Add skip_vcr: true

Signed-off-by: Modular Magician <magic-modules@google.com>
  • Loading branch information
modular-magician authored May 3, 2022
1 parent 112db4e commit 7b29295
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .changelog/5996.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
```release-note:none
```
12 changes: 12 additions & 0 deletions google/resource_cgc_snippet_generated_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ resource "google_compute_instance" "spot_vm_instance" {
}

func TestAccCGCSnippet_sqlDatabaseInstanceSqlserverExample(t *testing.T) {
skipIfVcr(t)
t.Parallel()

context := map[string]interface{}{
Expand Down Expand Up @@ -208,6 +209,17 @@ resource "google_sql_database_instance" "instance" {
deletion_protection = "%{deletion_protection}"
}
# [END cloud_sql_sqlserver_instance_80_db_n1_s2]
resource "random_password" "pwd" {
length = 16
special = false
}
resource "google_sql_user" "user" {
name = "user"
instance = google_sql_database_instance.instance.name
password = random_password.pwd.result
}
`, context)
}

Expand Down

0 comments on commit 7b29295

Please sign in to comment.