-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #34 from Infisical/daniel/project-interactions
Feat: Add projects to Terraform Provider
- Loading branch information
Showing
12 changed files
with
796 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "infisical_projects Data Source - terraform-provider-infisical" | ||
subcategory: "" | ||
description: |- | ||
Interact with Infisical projects. Only Machine Identity authentication is supported for this data source. | ||
--- | ||
|
||
# infisical_projects (Data Source) | ||
|
||
Interact with Infisical projects. Only Machine Identity authentication is supported for this data source. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
terraform { | ||
required_providers { | ||
infisical = { | ||
# version = <latest version> | ||
source = "infisical/infisical" | ||
} | ||
} | ||
} | ||
provider "infisical" { | ||
host = "https://app.infisical.com" # Only required if using self hosted instance of Infisical, default is https://app.infisical.com | ||
client_id = "<machine-identity-client-id>" | ||
client_secret = "<machine-identity-client-secret>" | ||
} | ||
data "infisical_projects" "test-project" { | ||
slug = "<project-slug>" | ||
} | ||
// Get the value of the "dev" environment | ||
output "dev-environment" { | ||
value = data.infisical_projects.test-project.environments["dev"] | ||
} | ||
// Get the entire project | ||
output "entire-project" { | ||
value = data.infisical_projects.test-project | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `slug` (String) The slug of the project to fetch | ||
|
||
### Read-Only | ||
|
||
- `auto_capitalization` (Boolean) The auto capitalization status of the project | ||
- `created_at` (String) The creation date of the project | ||
- `environments` (Attributes Map) (see [below for nested schema](#nestedatt--environments)) | ||
- `id` (String) The ID of the project | ||
- `name` (String) The name of the project | ||
- `org_id` (String) The ID of the organization to which the project belongs | ||
- `updated_at` (String) The last update date of the project | ||
- `upgrade_status` (String) The upgrade status of the project | ||
- `version` (Number) The version of the project | ||
|
||
<a id="nestedatt--environments"></a> | ||
### Nested Schema for `environments` | ||
|
||
Read-Only: | ||
|
||
- `id` (String) The ID of the environment | ||
- `name` (String) The name of the environment | ||
- `slug` (String) The slug of the environment |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "infisical_project Resource - terraform-provider-infisical" | ||
subcategory: "" | ||
description: |- | ||
Create projects & save to Infisical. Only Machine Identity authentication is supported for this data source. | ||
--- | ||
|
||
# infisical_project (Resource) | ||
|
||
Create projects & save to Infisical. Only Machine Identity authentication is supported for this data source. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
terraform { | ||
required_providers { | ||
infisical = { | ||
# version = <latest version> | ||
source = "infisical/infisical" | ||
} | ||
} | ||
} | ||
provider "infisical" { | ||
host = "https://app.infisical.com" # Only required if using self hosted instance of Infisical, default is https://app.infisical.com | ||
client_id = "<machine-identity-client-id>" | ||
client_secret = "<machine-identity-client-secret>" | ||
} | ||
resource "infisical_project" "gcp-project" { | ||
name = "GCP Project" | ||
slug = "gcp-project" | ||
} | ||
resource "infisical_project" "aws-project" { | ||
name = "AWS Project" | ||
slug = "aws-project" | ||
} | ||
resource "infisical_project" "azure-project" { | ||
name = "Azure Project" | ||
slug = "azure-project" | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `name` (String) The name of the project | ||
- `slug` (String) The slug of the project | ||
|
||
### Read-Only | ||
|
||
- `last_updated` (String) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
terraform { | ||
required_providers { | ||
infisical = { | ||
# version = <latest version> | ||
source = "infisical/infisical" | ||
} | ||
} | ||
} | ||
|
||
provider "infisical" { | ||
host = "https://app.infisical.com" # Only required if using self hosted instance of Infisical, default is https://app.infisical.com | ||
client_id = "<machine-identity-client-id>" | ||
client_secret = "<machine-identity-client-secret>" | ||
} | ||
|
||
data "infisical_projects" "test-project" { | ||
slug = "<project-slug>" | ||
} | ||
|
||
// Get the value of the "dev" environment | ||
output "dev-environment" { | ||
value = data.infisical_projects.test-project.environments["dev"] | ||
} | ||
|
||
// Get the entire project | ||
output "entire-project" { | ||
value = data.infisical_projects.test-project | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
terraform { | ||
required_providers { | ||
infisical = { | ||
# version = <latest version> | ||
source = "infisical/infisical" | ||
} | ||
} | ||
} | ||
|
||
provider "infisical" { | ||
host = "https://app.infisical.com" # Only required if using self hosted instance of Infisical, default is https://app.infisical.com | ||
client_id = "<machine-identity-client-id>" | ||
client_secret = "<machine-identity-client-secret>" | ||
} | ||
|
||
resource "infisical_project" "gcp-project" { | ||
name = "GCP Project" | ||
slug = "gcp-project" | ||
} | ||
|
||
resource "infisical_project" "aws-project" { | ||
name = "AWS Project" | ||
slug = "aws-project" | ||
} | ||
|
||
resource "infisical_project" "azure-project" { | ||
name = "Azure Project" | ||
slug = "azure-project" | ||
} | ||
|
||
|
Oops, something went wrong.