diff --git a/README.md b/README.md
index 9dffdf98..03dbbd5e 100644
--- a/README.md
+++ b/README.md
@@ -4,12 +4,12 @@
[![Slack](https://img.shields.io/badge/Slack-4A154B?style=for-the-badge&logo=slack&logoColor=white)](https://join.slack.com/t/devex-community/shared_invite/zt-1bmf5621e-GGfuJdMPK2D8UN58qL4E_g)
-
Port is the Developer Platform meant to supercharge your DevOps and Developers, and allow you to regain control of your environment.
### Docs
-* [Provider Docs](https://registry.terraform.io/providers/port-labs/port/latest/docs)
-* [Port Docs](https://docs.getport.io/)
+
+- [Provider Docs](https://registry.terraform.io/providers/port-labs/port/latest/docs)
+- [Port Docs](https://docs.getport.io/)
## Installation
@@ -24,7 +24,7 @@ terraform {
}
provider "port" {}
-resource "port_entity" "microservice" {
+resource "port-labs_entity" "microservice" {
title = "monolith"
blueprint = "microservice_blueprint"
properties {
diff --git a/docs/resources/entity.md b/docs/resources/entity.md
index 6b81978c..2930058c 100644
--- a/docs/resources/entity.md
+++ b/docs/resources/entity.md
@@ -1,18 +1,17 @@
---
# generated by https://github.com/hashicorp/terraform-plugin-docs
-page_title: "port_entity Resource - terraform-provider-port"
+page_title: "port-labs_entity Resource - terraform-provider-port"
subcategory: ""
description: |-
Port entity
---
-# port_entity (Resource)
+# port-labs_entity (Resource)
Port entity
-
-
+
## Schema
### Required
@@ -35,6 +34,7 @@ Port entity
- `updated_by` (String)
+
### Nested Schema for `properties`
Required:
@@ -47,13 +47,11 @@ Optional:
- `items` (List of String) The list of items, in case the type of this property is a list
- `value` (String) The value for this property
-
+
### Nested Schema for `relations`
Required:
- `identifier` (String) The id of the connected entity
- `name` (String) The name of the relation
-
-
diff --git a/examples/main.tf b/examples/main.tf
index 8fdd256c..8746c4ed 100644
--- a/examples/main.tf
+++ b/examples/main.tf
@@ -1,19 +1,19 @@
terraform {
required_providers {
port = {
- source = "port-labs/port"
+ source = "port-labs/port-labs"
version = "~> 0.0.1"
}
}
}
-provider "port" {}
+provider "port-labs" {}
-resource "port_entity" "microservice" {
- title = "monolith"
+resource "port-labs_entity" "microservice" {
+ title = "monolith"
blueprint = "microservice_blueprint"
properties {
- name = "microservice_name"
+ name = "microservice_name"
value = "golang_monolith"
- type = "string"
+ type = "string"
}
-}
\ No newline at end of file
+}
diff --git a/examples/provider/basic/main.tf b/examples/provider/basic/main.tf
index de3da2e8..b39cabdd 100644
--- a/examples/provider/basic/main.tf
+++ b/examples/provider/basic/main.tf
@@ -1,11 +1,11 @@
provider "port" {}
-resource "port_entity" "microservice" {
- title = "monolith"
+resource "port-labs_entity" "microservice" {
+ title = "monolith"
blueprint = "microservice_blueprint"
properties {
- name = "microservice_name"
+ name = "microservice_name"
value = "golang_monolith"
- type = "string"
+ type = "string"
}
-}
\ No newline at end of file
+}
diff --git a/examples/resources/port_entity/main.tf b/examples/resources/port_entity/main.tf
index 4c28d9aa..b71229c7 100644
--- a/examples/resources/port_entity/main.tf
+++ b/examples/resources/port_entity/main.tf
@@ -1,9 +1,9 @@
-resource "port_entity" "microservice" {
+resource "port-labs_entity" "microservice" {
title = "monolith"
blueprint = "microservice_blueprint"
relations {
name = "tf-relation"
- identifier = port_entity.prod_env.id
+ identifier = port-labs_entity.prod_env.id
}
properties {
name = "microservice_name"
@@ -12,7 +12,7 @@ resource "port_entity" "microservice" {
}
}
-resource "port_entity" "prod_env" {
+resource "port-labs_entity" "prod_env" {
title = "production"
blueprint = "environments"
properties {
diff --git a/port/provider.go b/port/provider.go
index dbbfcd85..9864c9e8 100644
--- a/port/provider.go
+++ b/port/provider.go
@@ -36,7 +36,7 @@ func Provider() *schema.Provider {
},
},
ResourcesMap: map[string]*schema.Resource{
- "port_entity": newEntityResource(),
+ "port-labs_entity": newEntityResource(),
},
DataSourcesMap: map[string]*schema.Resource{},
ConfigureContextFunc: providerConfigure,
diff --git a/port/resource_port_entity_test.go b/port/resource_port_entity_test.go
index ac8f82e5..13e0ab46 100644
--- a/port/resource_port_entity_test.go
+++ b/port/resource_port_entity_test.go
@@ -9,8 +9,8 @@ import (
func TestAccPortEntityUpdateProp(t *testing.T) {
var testAccActionConfigCreate = `
- provider "port" {}
- resource "port_entity" "microservice" {
+ provider "port-labs" {}
+ resource "port-labs_entity" "microservice" {
title = "monolith"
blueprint = "tf-provider-test-bp"
properties {
@@ -21,8 +21,8 @@ func TestAccPortEntityUpdateProp(t *testing.T) {
}
`
var testAccActionConfigUpdate = `
- provider "port" {}
- resource "port_entity" "microservice" {
+ provider "port-labs" {}
+ resource "port-labs_entity" "microservice" {
title = "monolith"
blueprint = "tf-provider-test-bp"
properties {
@@ -34,7 +34,7 @@ func TestAccPortEntityUpdateProp(t *testing.T) {
`
resource.Test(t, resource.TestCase{
Providers: map[string]*schema.Provider{
- "port": Provider(),
+ "port-labs": Provider(),
},
Steps: []resource.TestStep{
{
@@ -42,7 +42,7 @@ func TestAccPortEntityUpdateProp(t *testing.T) {
},
{
Config: testAccActionConfigUpdate,
- Check: resource.TestCheckResourceAttr("port_entity.microservice", "properties.0.value", "hedwig2"),
+ Check: resource.TestCheckResourceAttr("port-labs_entity.microservice", "properties.0.value", "hedwig2"),
},
},
})
@@ -50,8 +50,8 @@ func TestAccPortEntityUpdateProp(t *testing.T) {
func TestAccPortEntity(t *testing.T) {
var testAccActionConfigCreate = `
- provider "port" {}
- resource "port_entity" "microservice" {
+ provider "port-labs" {}
+ resource "port-labs_entity" "microservice" {
title = "monolith"
blueprint = "tf-provider-test-bp"
properties {
@@ -83,7 +83,7 @@ func TestAccPortEntity(t *testing.T) {
`
resource.Test(t, resource.TestCase{
Providers: map[string]*schema.Provider{
- "port": Provider(),
+ "port-labs": Provider(),
},
Steps: []resource.TestStep{
{
@@ -95,13 +95,13 @@ func TestAccPortEntity(t *testing.T) {
func TestAccPortEntitiesRelation(t *testing.T) {
var testAccActionConfigCreate = `
- provider "port" {}
- resource "port_entity" "microservice" {
+ provider "port-labs" {}
+ resource "port-labs_entity" "microservice" {
title = "monolith"
blueprint = "tf-provider-test-bp"
relations {
name = "tf-relation"
- identifier = port_entity.microservice2.id
+ identifier = port-labs_entity.microservice2.id
}
properties {
name = "text"
@@ -109,7 +109,7 @@ func TestAccPortEntitiesRelation(t *testing.T) {
type = "string"
}
}
- resource "port_entity" "microservice2" {
+ resource "port-labs_entity" "microservice2" {
title = "monolith2"
blueprint = "tf-provider-test-bp2"
properties {
@@ -121,7 +121,7 @@ func TestAccPortEntitiesRelation(t *testing.T) {
`
resource.Test(t, resource.TestCase{
Providers: map[string]*schema.Provider{
- "port": Provider(),
+ "port-labs": Provider(),
},
Steps: []resource.TestStep{
{