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

PORT-9948 bug wrong action docs in the terraform #180

Merged
merged 8 commits into from
Sep 5, 2024
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions docs/data-sources/port_search.md
Original file line number Diff line number Diff line change
Expand Up @@ -225,5 +225,3 @@ Read-Only:
- `identifier` (String)
- `level` (String)
- `status` (String)


49 changes: 28 additions & 21 deletions docs/resources/port_action.md
Original file line number Diff line number Diff line change
Expand Up @@ -343,6 +343,7 @@ Optional:
- `entity_deleted_event` (Attributes) Entity deleted event trigger (see [below for nested schema](#nestedatt--automation_trigger--entity_deleted_event))
- `entity_updated_event` (Attributes) Entity updated event trigger (see [below for nested schema](#nestedatt--automation_trigger--entity_updated_event))
- `jq_condition` (Attributes) JQ condition for automation trigger (see [below for nested schema](#nestedatt--automation_trigger--jq_condition))
- `run_updated_event` (Attributes) Run updated event trigger (see [below for nested schema](#nestedatt--automation_trigger--run_updated_event))
- `timer_property_expired_event` (Attributes) Timer property expired event trigger (see [below for nested schema](#nestedatt--automation_trigger--timer_property_expired_event))

<a id="nestedatt--automation_trigger--any_entity_change_event"></a>
Expand Down Expand Up @@ -389,6 +390,14 @@ Optional:
- `combinator` (String) The combinator of the condition


<a id="nestedatt--automation_trigger--run_updated_event"></a>
### Nested Schema for `automation_trigger.run_updated_event`

Required:

- `action_identifier` (String) The action identifier of the updated run


<a id="nestedatt--automation_trigger--timer_property_expired_event"></a>
### Nested Schema for `automation_trigger.timer_property_expired_event`

Expand Down Expand Up @@ -480,17 +489,17 @@ Optional:

Optional:

- `boolean_items` (Attributes) The items of the array property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--boolean_items))
- `boolean_items` (Attributes) An array of boolean items within the property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--boolean_items))
kodjomiles marked this conversation as resolved.
Show resolved Hide resolved
- `default_jq_query` (String) The default jq query of the array property
- `depends_on` (List of String) The properties that this property depends on
- `description` (String) The description of the property
- `icon` (String) The icon of the property
- `max_items` (Number) The max items of the array property
- `min_items` (Number) The min items of the array property
- `number_items` (Attributes) The items of the array property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--number_items))
- `object_items` (Attributes) The items of the array property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--object_items))
- `number_items` (Attributes) An array of number items within the property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--number_items))
- `object_items` (Attributes) An array of object items within the property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--object_items))
- `required` (Boolean) Whether the property is required, by default not required, this property can't be set at the same time if `required_jq_query` is set, and only supports true as value
- `string_items` (Attributes) The items of the array property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--string_items))
- `string_items` (Attributes) An array of string items within the property (see [below for nested schema](#nestedatt--self_service_trigger--user_properties--array_props--string_items))
- `title` (String) The title of the property
- `visible` (Boolean) The visibility of the array property
- `visible_jq_query` (String) The visibility condition jq query of the array property
Expand All @@ -500,38 +509,38 @@ Optional:

Optional:

- `default` (List of Boolean) The default of the items
- `default` (List of Boolean) The default values for the boolean items


<a id="nestedatt--self_service_trigger--user_properties--array_props--number_items"></a>
### Nested Schema for `self_service_trigger.user_properties.array_props.visible_jq_query`

Optional:

- `default` (List of Number) The default of the items
- `enum` (List of Number) The enum of the items
- `enum_jq_query` (String) The enum jq query of the number items
- `default` (List of Number) The default values for the number items
- `enum` (List of Number) The enum of possible values for the number items
- `enum_jq_query` (String) The jq query for the enum number items


<a id="nestedatt--self_service_trigger--user_properties--array_props--object_items"></a>
### Nested Schema for `self_service_trigger.user_properties.array_props.visible_jq_query`

Optional:

- `default` (List of Map of String) The default of the items
- `default` (List of Map of String) The default values for the object items


<a id="nestedatt--self_service_trigger--user_properties--array_props--string_items"></a>
### Nested Schema for `self_service_trigger.user_properties.array_props.visible_jq_query`

Optional:

- `blueprint` (String) The blueprint identifier the property relates to
- `dataset` (String) The dataset of an the entity-format items
- `default` (List of String) The default of the items
- `enum` (List of String) The enum of the items
- `enum_jq_query` (String) The enum jq query of the string items
- `format` (String) The format of the items
- `blueprint` (String) The blueprint identifier related to each string item
- `dataset` (String) The dataset of the entity-format items
- `default` (List of String) The default value of the items
- `enum` (List of String) The enum of possible values for the string items
- `enum_jq_query` (String) The jq query for the enum of string items
- `format` (String) The format of the string property, Accepted values include `date-time`, `url`, `email`, `ipv4`, `ipv6`, `yaml`, `entity`, `user`, `team`, `proto`, `markdown`



Expand Down Expand Up @@ -580,7 +589,7 @@ Optional:
- `default_jq_query` (String) The default jq query of the object property
- `depends_on` (List of String) The properties that this property depends on
- `description` (String) The description of the property
- `encryption` (String) The algorithm to encrypt the property with
- `encryption` (String) The algorithm to encrypt the property with. Accepted value: `aes256-gcm`
- `icon` (String) The icon of the property
- `required` (Boolean) Whether the property is required, by default not required, this property can't be set at the same time if `required_jq_query` is set, and only supports true as value
- `title` (String) The title of the property
Expand All @@ -599,10 +608,10 @@ Optional:
- `default_jq_query` (String) The default jq query of the string property
- `depends_on` (List of String) The properties that this property depends on
- `description` (String) The description of the property
- `encryption` (String) The algorithm to encrypt the property with
- `encryption` (String) The algorithm to encrypt the property with. Accepted value: `aes256-gcm`
- `enum` (List of String) The enum of the string property
- `enum_jq_query` (String) The enum jq query of the string property
- `format` (String) The format of the string property
- `format` (String) The format of the string property, Accepted values include `date-time`, `url`, `email`, `ipv4`, `ipv6`, `yaml`, `entity`, `user`, `team`, `proto`, `markdown`
- `icon` (String) The icon of the property
- `max_length` (Number) The max length of the string property
- `min_length` (Number) The min length of the string property
Expand Down Expand Up @@ -680,10 +689,8 @@ Required:

Optional:

- `agent` (String) Use the agent to invoke the action
- `agent` (String) Specifies whether to use an agent to invoke the action. This can be a boolean value (`'true''` or `'false'`) or a JQ if dynamic evaluation is needed.
- `body` (String) The Webhook body should be in `JSON` format, encoded as a string. Use [jsonencode](https://developer.hashicorp.com/terraform/language/functions/jsonencode) to encode arrays or objects. Learn about how to [define the action payload](https://docs.getport.io/create-self-service-experiences/setup-backend/#define-the-actions-payload).
- `headers` (Map of String) The HTTP headers for invoking the action. They should be encoded as a key-value object to a string using [jsonencode](https://developer.hashicorp.com/terraform/language/functions/jsonencode). Learn about how to [define the action payload](https://docs.getport.io/create-self-service-experiences/setup-backend/#define-the-actions-payload).
- `method` (String) The HTTP method to invoke the action
- `synchronized` (String) Synchronize the action


6 changes: 2 additions & 4 deletions docs/resources/port_action_permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ page_title: "port_action_permissions Resource - terraform-provider-port-labs"
subcategory: ""
description: |-
Action Permissions resource
Docs for the Action Permissions resource can be found here https://docs.getport.io/create-self-service-experiences/set-self-service-actions-rbac/examples.
Docs for the Action Permissions resource can be found here https://docs.getport.io/actions-and-automations/create-self-service-experiences/set-self-service-actions-rbac/?config-method=terraform.
Example Usage
hcl
resource "port_action_permissions" "restart_microservice_permissions" {
Expand Down Expand Up @@ -107,7 +107,7 @@ description: |-

# Action Permissions resource

Docs for the Action Permissions resource can be found [here](https://docs.getport.io/create-self-service-experiences/set-self-service-actions-rbac/examples).
Docs for the Action Permissions resource can be found [here](https://docs.getport.io/actions-and-automations/create-self-service-experiences/set-self-service-actions-rbac/?config-method=terraform).

## Example Usage

Expand Down Expand Up @@ -265,5 +265,3 @@ Optional:
- `roles` (List of String) The roles with execution permission
- `teams` (List of String) The teams with execution permission
- `users` (List of String) The users with execution permission


6 changes: 2 additions & 4 deletions docs/resources/port_aggregation_properties.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ subcategory: ""
description: |-
Aggregation Properties
This resource allows you to manage aggregation properties of a blueprint.
See the Port documentation https://docs.getport.io/build-your-software-catalog/define-your-data-model/setup-blueprint/properties/aggregation-properties/ for more information about aggregation properties.
See the Port documentation https://docs.getport.io/build-your-software-catalog/customize-integrations/configure-data-model/setup-blueprint/properties/aggregation-property/ for more information about aggregation properties.
Supported Methods:
count_entities - Count the entities of the target blueprintaverage_entities - Average the entities of the target blueprint by time periodsaveragebyproperty - Calculate the average by property value of the target entitiesaggregatebyproperty - Calculate the aggregate by property value of the target entities, such as sum, min, max, median
Example Usage
Expand Down Expand Up @@ -276,7 +276,7 @@ description: |-

This resource allows you to manage aggregation properties of a blueprint.

See the [Port documentation](https://docs.getport.io/build-your-software-catalog/define-your-data-model/setup-blueprint/properties/aggregation-properties/) for more information about aggregation properties.
See the [Port documentation](https://docs.getport.io/build-your-software-catalog/customize-integrations/configure-data-model/setup-blueprint/properties/aggregation-property/) for more information about aggregation properties.


Supported Methods:
Expand Down Expand Up @@ -645,5 +645,3 @@ Optional:

- `average_of` (String) The time periods to calculate the average of, e.g. hour, day, week, month
- `measure_time_by` (String) The property name on which to calculate the the time periods, e.g. $createdAt, $updated_at or any other date property


2 changes: 0 additions & 2 deletions docs/resources/port_blueprint.md
Original file line number Diff line number Diff line change
Expand Up @@ -499,5 +499,3 @@ Required:
Optional:

- `agent` (Boolean) The agent of the webhook changelog destination


2 changes: 0 additions & 2 deletions docs/resources/port_blueprint_permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -450,5 +450,3 @@ Optional:
- `roles` (List of String) Roles with update specific relation permissions
- `teams` (List of String) Teams with update specific relation permissions
- `users` (List of String) Users with update specific relation permissions


2 changes: 0 additions & 2 deletions docs/resources/port_entity.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,5 +67,3 @@ Optional:

- `many_relations` (Map of List of String) The many relation of the entity
- `single_relations` (Map of String) The single relation of the entity


2 changes: 0 additions & 2 deletions docs/resources/port_integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,5 +128,3 @@ Required:
Optional:

- `agent` (Boolean) The agent of the webhook changelog destination


2 changes: 0 additions & 2 deletions docs/resources/port_page.md
Original file line number Diff line number Diff line change
Expand Up @@ -481,5 +481,3 @@ terraform import port_page.home_page "\$home"
- `id` (String) The ID of this resource.
- `updated_at` (String) The last update date of the page
- `updated_by` (String) The last updater of the page


2 changes: 0 additions & 2 deletions docs/resources/port_page_permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,5 +121,3 @@ Optional:
- `roles` (List of String) The roles with read permission
- `teams` (List of String) The teams with read permission
- `users` (List of String) The users with read permission


21 changes: 10 additions & 11 deletions docs/resources/port_scorecard.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ description: |-
operator = "isNotEmpty"
}),
jsonencode({
property = "author",
operator : "=",
property = "author"
operator : "="
value : "myValue"
})
]
Expand Down Expand Up @@ -97,6 +97,7 @@ description: |-
portblueprint.microservice
]
}
```
Example Usage with Levels
This will override the default levels (Basic, Bronze, Silver, Gold) with the provided levels: Not Ready, Partially Ready, Ready.
```hcl
Expand Down Expand Up @@ -156,8 +157,8 @@ description: |-
operator = "isNotEmpty"
}),
jsonencode({
property = "author",
operator : "=",
property = "author"
operator : "="
value : "myValue"
})
]
Expand Down Expand Up @@ -262,8 +263,8 @@ resource "port_scorecard" "readiness" {
operator = "isNotEmpty"
}),
jsonencode({
property = "author",
operator : "=",
property = "author"
operator : "="
value : "myValue"
})
]
Expand Down Expand Up @@ -309,7 +310,7 @@ resource "port_scorecard" "readiness" {
]
}


```

## Example Usage with Levels

Expand Down Expand Up @@ -375,8 +376,8 @@ resource "port_scorecard" "readiness" {
operator = "isNotEmpty"
}),
jsonencode({
property = "author",
operator : "=",
property = "author"
operator : "="
value : "myValue"
})
]
Expand Down Expand Up @@ -475,5 +476,3 @@ Required:

- `color` (String) The color of the level
- `title` (String) The title of the level


2 changes: 0 additions & 2 deletions docs/resources/port_team.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,3 @@ Team resource
- `id` (String) The ID of this resource.
- `provider_name` (String) The provider of the team
- `updated_at` (String) The last update date of the team


2 changes: 0 additions & 2 deletions docs/resources/port_webhook.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,5 +75,3 @@ Optional:
- `signature_algorithm` (String) The signature algorithm of the webhook
- `signature_header_name` (String) The signature header name of the webhook
- `signature_prefix` (String) The signature prefix of the webhook


3 changes: 1 addition & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ require (
require (
github.com/ProtonMail/go-crypto v0.0.0-20230626094100-7e9e0395ebec // indirect
github.com/cloudflare/circl v1.3.3 // indirect
github.com/gertd/go-pluralize v0.2.1 // indirect
github.com/hashicorp/terraform-plugin-sdk/v2 v2.27.0 // indirect
github.com/vmihailenco/msgpack/v5 v5.3.5 // indirect
github.com/vmihailenco/tagparser/v2 v2.0.0 // indirect
Expand Down Expand Up @@ -48,7 +47,7 @@ require (
github.com/hashicorp/terraform-json v0.17.1 // indirect
github.com/hashicorp/terraform-plugin-framework-validators v0.10.0
github.com/hashicorp/terraform-plugin-go v0.18.0
github.com/hashicorp/terraform-plugin-log v0.9.0 // indirect
github.com/hashicorp/terraform-plugin-log v0.9.0
github.com/hashicorp/terraform-plugin-testing v1.3.0
github.com/hashicorp/terraform-registry-address v0.2.1 // indirect
github.com/hashicorp/terraform-svchost v0.1.1 // indirect
Expand Down
2 changes: 0 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,6 @@ github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYF
github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs=
github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw=
github.com/frankban/quicktest v1.14.4 h1:g2rn0vABPOOXmZUj+vbmUp0lPoXEMuhTpIluN0XL9UY=
github.com/gertd/go-pluralize v0.2.1 h1:M3uASbVjMnTsPb0PNqg+E/24Vwigyo/tvyMTtAlLgiA=
github.com/gertd/go-pluralize v0.2.1/go.mod h1:rbYaKDbsXxmRfr8uygAEKhOWsjyrrqrkHVpZvoOp8zk=
github.com/go-git/gcfg v1.5.0 h1:Q5ViNfGF8zFgyJWPqYwA7qGFoMTEiBmdlkcfRmpIMa4=
github.com/go-git/go-billy/v5 v5.4.1 h1:Uwp5tDRkPr+l/TnbHOQzp+tmJfLceOlbVucgpTz8ix4=
github.com/go-git/go-git/v5 v5.6.1 h1:q4ZRqQl4pR/ZJHc1L5CFjGA1a10u76aV1iC+nh+bHsk=
Expand Down
2 changes: 1 addition & 1 deletion port/action-permissions/schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ var ActionPermissionsResourceMarkdownDescription = `

# Action Permissions resource

Docs for the Action Permissions resource can be found [here](https://docs.getport.io/create-self-service-experiences/set-self-service-actions-rbac/examples).
Docs for the Action Permissions resource can be found [here](https://docs.getport.io/actions-and-automations/create-self-service-experiences/set-self-service-actions-rbac/?config-method=terraform).

## Example Usage

Expand Down
Loading
Loading