From 7cf136f331bf82859f8a0918968b6d57869b4f6e Mon Sep 17 00:00:00 2001 From: Paul Rey Date: Fri, 23 Feb 2024 16:43:49 +0100 Subject: [PATCH] Update rdb_privilege.md (#2414) Update documentation and add coherence to the example. --- docs/resources/rdb_privilege.md | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/docs/resources/rdb_privilege.md b/docs/resources/rdb_privilege.md index 005248244..3a57005cb 100644 --- a/docs/resources/rdb_privilege.md +++ b/docs/resources/rdb_privilege.md @@ -26,21 +26,19 @@ resource "scaleway_rdb_database" "main" { name = "database" } -resource "scaleway_rdb_privilege" "main" { - instance_id = scaleway_rdb_instance.main.id - user_name = "my-db-user" - database_name = "my-db-name" - permission = "all" - - depends_on = [scaleway_rdb_user.main, scaleway_rdb_database.main] -} - resource "scaleway_rdb_user" "main" { instance_id = scaleway_rdb_instance.main.id - name = "foobar" + name = "my-db-user" password = "thiZ_is_v&ry_s3cret" is_admin = false } + +resource "scaleway_rdb_privilege" "main" { + instance_id = scaleway_rdb_instance.main.id + user_name = scaleway_rdb_user.main.name + database_name = scaleway_rdb_database.main.name + permission = "all" +} ``` ## Argument Reference