github.com/nevins-b/terraform@v0.3.8-0.20170215184714-bbae22007d5a/website/source/docs/providers/google/r/google_project_iam_policy.html.markdown (about)

     1  ---
     2  layout: "google"
     3  page_title: "Google: google_project_iam_policy"
     4  sidebar_current: "docs-google-project-iam-policy"
     5  description: |-
     6   Allows management of an IAM policy for a Google Cloud Platform project. 
     7  ---
     8  
     9  # google\_project\_iam\_policy
    10  
    11  Allows creation and management of an IAM policy for an existing Google Cloud
    12  Platform project.
    13  
    14  ## Example Usage
    15  
    16  ```js
    17  resource "google_project_iam_policy" "project" {
    18      project = "your-project-id"
    19      policy_data = "${data.google_iam_policy.admin.policy_data}"
    20  }
    21  
    22  data "google_iam_policy" "admin" {
    23    binding {
    24      role = "roles/editor"
    25      members = [
    26        "user:jane@example.com",
    27      ]
    28    }
    29  }
    30  ```
    31  
    32  ## Argument Reference
    33  
    34  The following arguments are supported:
    35  
    36  * `project` - (Required) The project ID.
    37      Changing this forces a new project to be created.
    38  
    39  * `policy_data` - (Required) The `google_iam_policy` data source that represents
    40      the IAM policy that will be applied to the project. The policy will be
    41      merged with any existing policy applied to the project.
    42  
    43      Changing this updates the policy.
    44  
    45      Deleting this removes the policy, but leaves the original project policy
    46      intact. If there are overlapping `binding` entries between the original
    47      project policy and the data source policy, they will be removed.
    48  
    49  * `authoritative` - (Optional) A boolean value indicating if this policy
    50      should overwrite any existing IAM policy on the project. When set to true,
    51      **any policies not in your config file will be removed**. This can **lock
    52      you out** of your project until an Organization Administrator grants you
    53      access again, so please exercise caution. If this argument is `true` and you
    54      want to delete the resource, you must set the `disable_project` argument to
    55      `true`, acknowledging that the project will be inaccessible to anyone but the
    56      Organization Admins, as it will no longer have an IAM policy.
    57  
    58  * `disable_project` - (Optional) A boolean value that must be set to `true`
    59      if you want to delete a `google_project_iam_policy` that is authoritative.
    60  
    61  ## Attributes Reference
    62  
    63  In addition to the arguments listed above, the following computed attributes are
    64  exported:
    65  
    66  * `etag` - (Computed) The etag of the project's IAM policy.
    67  
    68  * `restore_policy` - (Computed) The IAM policy that will be resotred when a
    69      non-authoritative policy resource is deleted.