File tree Expand file tree Collapse file tree 1 file changed +56
-0
lines changed Expand file tree Collapse file tree 1 file changed +56
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ layout : " tfe"
3
+ page_title : " Terraform Enterprise: tfe_project_policy_set"
4
+ description : |-
5
+ Add a policy set to a project
6
+ ---
7
+
8
+ # tfe_project_policy_set
9
+
10
+ Adds and removes policy sets from a project
11
+
12
+ ## Example Usage
13
+
14
+ Basic usage:
15
+
16
+ ``` hcl
17
+ resource "tfe_organization" "test" {
18
+ name = "my-org-name"
19
+
20
+ }
21
+
22
+ resource "tfe_project" "test" {
23
+ name = "my-project-name"
24
+ organization = tfe_organization.test.name
25
+ }
26
+
27
+ resource "tfe_policy_set" "test" {
28
+ name = "my-policy-set"
29
+ description = "Some description."
30
+ organization = tfe_organization.test.name
31
+ }
32
+
33
+ resource "tfe_project_policy_set" "test" {
34
+ policy_set_id = tfe_policy_set.test.id
35
+ project_id = tfe_project.test.id
36
+ }
37
+ ```
38
+
39
+ ## Argument Reference
40
+
41
+ The following arguments are supported:
42
+
43
+ * ` policy_set_id ` - (Required) ID of the policy set.
44
+ * ` project_id ` - (Required) Project ID to add the policy set to.
45
+
46
+ ## Attributes Reference
47
+
48
+ * ` id ` - The ID of the policy set attachment. ID format: ` <project-id>_<policy-set-id> `
49
+
50
+ ## Import
51
+
52
+ Project Policy Sets can be imported; use ` <ORGANIZATION>/<PROJECT ID>/<POLICY SET NAME> ` . For example:
53
+
54
+ ``` shell
55
+ terraform import tfe_project_policy_set.test ' my-org-name/project/policy-set-name'
56
+ ```
You can’t perform that action at this time.
0 commit comments