Skip to content

Commit

Permalink
Upgrade terraform to latest + Add webhook resource (#64)
Browse files Browse the repository at this point in the history
* Upgrade terraform to latest + Add webhook resource

* feat: Upgrade tf to latest + Add webhook resource

---------

Co-authored-by: Engin Diri <[email protected]>
  • Loading branch information
dvirsegev and dirien authored Aug 14, 2023
1 parent 3a1be15 commit 2339df5
Show file tree
Hide file tree
Showing 17 changed files with 2,407 additions and 36 deletions.
26 changes: 23 additions & 3 deletions provider/cmd/pulumi-resource-port/bridge-metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
"resources": {
"port:index/action:Action": "port_action",
"port:index/blueprint:Blueprint": "port_blueprint",
"port:index/entity:Entity": "port_entity"
"port:index/entity:Entity": "port_entity",
"port:index/webhook:Webhook": "port_webhook"
},
"renamedProperties": {
"port:index/ActionGithubMethod:ActionGithubMethod": {
Expand Down Expand Up @@ -42,13 +43,17 @@
"jqQuery": "jq_query"
},
"port:index/ActionUserPropertiesArrayPropsNumberItems:ActionUserPropertiesArrayPropsNumberItems": {
"defaults": "default"
"defaults": "default",
"enumJqQuery": "enum_jq_query",
"enums": "enum"
},
"port:index/ActionUserPropertiesArrayPropsObjectItems:ActionUserPropertiesArrayPropsObjectItems": {
"defaults": "default"
},
"port:index/ActionUserPropertiesArrayPropsStringItems:ActionUserPropertiesArrayPropsStringItems": {
"defaults": "default"
"defaults": "default",
"enumJqQuery": "enum_jq_query",
"enums": "enum"
},
"port:index/ActionUserPropertiesBooleanProps:ActionUserPropertiesBooleanProps": {
"defaultJqQuery": "default_jq_query",
Expand Down Expand Up @@ -144,6 +149,15 @@
"manyRelations": "many_relations",
"singleRelations": "single_relations"
},
"port:index/WebhookMapping:WebhookMapping": {
"itemsToParse": "items_to_parse"
},
"port:index/WebhookSecurity:WebhookSecurity": {
"requestIdentifierPath": "request_identifier_path",
"signatureAlgorithm": "signature_algorithm",
"signatureHeaderName": "signature_header_name",
"signaturePrefix": "signature_prefix"
},
"port:index/action:Action": {
"approvalEmailNotification": "approval_email_notification",
"approvalWebhookNotification": "approval_webhook_notification",
Expand Down Expand Up @@ -174,6 +188,12 @@
"updatedAt": "updated_at",
"updatedBy": "updated_by"
},
"port:index/webhook:Webhook": {
"createdAt": "created_at",
"createdBy": "created_by",
"updatedAt": "updated_at",
"updatedBy": "updated_by"
},
"port:index:Provider": {
"baseUrl": "base_url",
"clientId": "client_id"
Expand Down
236 changes: 236 additions & 0 deletions provider/cmd/pulumi-resource-port/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,15 @@
"items": {
"type": "number"
}
},
"enumJqQuery": {
"type": "string"
},
"enums": {
"type": "array",
"items": {
"type": "number"
}
}
},
"type": "object"
Expand Down Expand Up @@ -357,6 +366,15 @@
"type": "string"
}
},
"enumJqQuery": {
"type": "string"
},
"enums": {
"type": "array",
"items": {
"type": "string"
}
},
"format": {
"type": "string"
}
Expand Down Expand Up @@ -1273,6 +1291,79 @@
}
},
"type": "object"
},
"port:index/WebhookMapping:WebhookMapping": {
"properties": {
"blueprint": {
"type": "string"
},
"entity": {
"$ref": "#/types/port:index/WebhookMappingEntity:WebhookMappingEntity"
},
"filter": {
"type": "string"
},
"itemsToParse": {
"type": "string"
}
},
"type": "object",
"required": [
"blueprint",
"entity"
]
},
"port:index/WebhookMappingEntity:WebhookMappingEntity": {
"properties": {
"icon": {
"type": "string"
},
"identifier": {
"type": "string"
},
"properties": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"relations": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"team": {
"type": "string"
},
"title": {
"type": "string"
}
},
"type": "object",
"required": [
"identifier"
]
},
"port:index/WebhookSecurity:WebhookSecurity": {
"properties": {
"requestIdentifierPath": {
"type": "string"
},
"secret": {
"type": "string"
},
"signatureAlgorithm": {
"type": "string"
},
"signatureHeaderName": {
"type": "string"
},
"signaturePrefix": {
"type": "string"
}
},
"type": "object"
}
},
"provider": {
Expand Down Expand Up @@ -1916,6 +2007,151 @@
},
"type": "object"
}
},
"port:index/webhook:Webhook": {
"properties": {
"createdAt": {
"type": "string",
"description": "The creation date of the webhook\n"
},
"createdBy": {
"type": "string",
"description": "The creator of the webhook\n"
},
"description": {
"type": "string",
"description": "The description of the webhook\n"
},
"enabled": {
"type": "boolean",
"description": "Whether the webhook is enabled\n"
},
"icon": {
"type": "string",
"description": "The icon of the webhook\n"
},
"identifier": {
"type": "string",
"description": "The identifier of the webhook\n"
},
"mappings": {
"type": "array",
"items": {
"$ref": "#/types/port:index/WebhookMapping:WebhookMapping"
},
"description": "The mappings of the webhook\n"
},
"security": {
"$ref": "#/types/port:index/WebhookSecurity:WebhookSecurity",
"description": "The security of the webhook\n"
},
"title": {
"type": "string",
"description": "The title of the webhook\n"
},
"updatedAt": {
"type": "string",
"description": "The last update date of the webhook\n"
},
"updatedBy": {
"type": "string",
"description": "The last updater of the webhook\n"
}
},
"required": [
"createdAt",
"createdBy",
"enabled",
"identifier",
"updatedAt",
"updatedBy"
],
"inputProperties": {
"description": {
"type": "string",
"description": "The description of the webhook\n"
},
"enabled": {
"type": "boolean",
"description": "Whether the webhook is enabled\n"
},
"icon": {
"type": "string",
"description": "The icon of the webhook\n"
},
"identifier": {
"type": "string",
"description": "The identifier of the webhook\n"
},
"mappings": {
"type": "array",
"items": {
"$ref": "#/types/port:index/WebhookMapping:WebhookMapping"
},
"description": "The mappings of the webhook\n"
},
"security": {
"$ref": "#/types/port:index/WebhookSecurity:WebhookSecurity",
"description": "The security of the webhook\n"
},
"title": {
"type": "string",
"description": "The title of the webhook\n"
}
},
"stateInputs": {
"description": "Input properties used for looking up and filtering Webhook resources.\n",
"properties": {
"createdAt": {
"type": "string",
"description": "The creation date of the webhook\n"
},
"createdBy": {
"type": "string",
"description": "The creator of the webhook\n"
},
"description": {
"type": "string",
"description": "The description of the webhook\n"
},
"enabled": {
"type": "boolean",
"description": "Whether the webhook is enabled\n"
},
"icon": {
"type": "string",
"description": "The icon of the webhook\n"
},
"identifier": {
"type": "string",
"description": "The identifier of the webhook\n"
},
"mappings": {
"type": "array",
"items": {
"$ref": "#/types/port:index/WebhookMapping:WebhookMapping"
},
"description": "The mappings of the webhook\n"
},
"security": {
"$ref": "#/types/port:index/WebhookSecurity:WebhookSecurity",
"description": "The security of the webhook\n"
},
"title": {
"type": "string",
"description": "The title of the webhook\n"
},
"updatedAt": {
"type": "string",
"description": "The last update date of the webhook\n"
},
"updatedBy": {
"type": "string",
"description": "The last updater of the webhook\n"
}
},
"type": "object"
}
}
}
}
14 changes: 7 additions & 7 deletions provider/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@ go 1.20
replace github.com/hashicorp/terraform-plugin-sdk/v2 => github.com/pulumi/terraform-plugin-sdk/v2 v2.0.0-20230327102345-3fa930f86570

require (
github.com/port-labs/terraform-provider-port-labs v1.2.3
github.com/pulumi/pulumi-terraform-bridge/pf v0.15.0
github.com/pulumi/pulumi-terraform-bridge/v3 v3.56.1
github.com/port-labs/terraform-provider-port-labs v1.4.0
github.com/pulumi/pulumi-terraform-bridge/pf v0.15.2
github.com/pulumi/pulumi-terraform-bridge/v3 v3.57.0
github.com/pulumi/pulumi/sdk/v3 v3.77.1
)

require (
cloud.google.com/go v0.110.4 // indirect
cloud.google.com/go/compute v1.20.1 // indirect
cloud.google.com/go/compute/metadata v0.2.3 // indirect
cloud.google.com/go/iam v1.1.0 // indirect
cloud.google.com/go/iam v1.1.1 // indirect
cloud.google.com/go/kms v1.12.1 // indirect
cloud.google.com/go/logging v1.7.0 // indirect
cloud.google.com/go/longrunning v0.5.1 // indirect
Expand Down Expand Up @@ -181,7 +181,7 @@ require (
github.com/pulumi/pulumi-java/pkg v0.9.4 // indirect
github.com/pulumi/pulumi-terraform-bridge/x/muxer v0.0.4 // indirect
github.com/pulumi/pulumi-yaml v1.1.1 // indirect
github.com/pulumi/pulumi/pkg/v3 v3.76.1 // indirect
github.com/pulumi/pulumi/pkg/v3 v3.77.1 // indirect
github.com/pulumi/schema-tools v0.1.2 // indirect
github.com/rivo/uniseg v0.4.4 // indirect
github.com/rogpeppe/go-internal v1.9.0 // indirect
Expand Down Expand Up @@ -229,8 +229,8 @@ require (
golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect
google.golang.org/api v0.126.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20230629202037-9506855d4529 // indirect
google.golang.org/genproto v0.0.0-20230726155614-23370e0ffb3e // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20230706204954-ccb25ca9f130 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
google.golang.org/grpc v1.57.0 // indirect
google.golang.org/protobuf v1.31.0 // indirect
Expand Down
Loading

0 comments on commit 2339df5

Please sign in to comment.