Skip to content

Commit

Permalink
Merge pull request #109 from akeyless-community/importExample
Browse files Browse the repository at this point in the history
Docs: add import example for resources where examples already exist
  • Loading branch information
renanaAkeyless authored Aug 22, 2024
2 parents 257724c + 41a83e6 commit 07f83eb
Show file tree
Hide file tree
Showing 10 changed files with 38 additions and 2 deletions.
6 changes: 6 additions & 0 deletions docs/resources/auth_method.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,4 +165,10 @@ Optional:
- `idp_metadata_url` (String) IDP metadata url
- `idp_metadata_xml_data` (String) IDP metadata xml data

## Import

Import is supported using the following syntax:

```shell
terraform import akeyless_auth_method.example /full-auth-method-path/and-name-in-akeyless
```
16 changes: 15 additions & 1 deletion docs/resources/auth_method_saml.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,15 @@ description: |-

SAML Auth Method Resource

## Example Usage

```terraform
resource "akeyless_auth_method_saml" "saml_auth" {
name = "auth-method-saml"
unique_identifier = "email"
idp_metadata_xml_data = file("saml-metadata.xml")
}
```

<!-- schema generated by tfplugindocs -->
## Schema
Expand All @@ -23,7 +31,6 @@ SAML Auth Method Resource
### Optional

- `access_expires` (Number) Access expiration date in Unix timestamp (select 0 for access without expiry date)
- `access_id` (String) Auth Method access ID
- `allowed_redirect_uri` (Set of String) Allowed redirect URIs after the authentication (default is https://console.akeyless.io/login-saml to enable SAML via Akeyless Console and http://127.0.0.1:* to enable SAML via akeyless CLI)
- `audit_logs_claims` (Set of String) Subclaims to include in audit logs
- `bound_ips` (Set of String) A CIDR whitelist with the IPs that the access is restricted to
Expand All @@ -35,6 +42,13 @@ SAML Auth Method Resource

### Read-Only

- `access_id` (String) Auth Method access ID
- `id` (String) The ID of this resource.

## Import

Import is supported using the following syntax:

```shell
terraform import akeyless_auth_method_saml.example /full-auth-method-saml-path/and-name-in-akeyless
```
6 changes: 6 additions & 0 deletions docs/resources/role.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,4 +118,10 @@ Optional:

- `rule_type` (String) item-rule, target-rule, role-rule, auth-method-rule

## Import

Import is supported using the following syntax:

```shell
terraform import akeyless_role.example /full-role-path/and-name-in-akeyless
```
6 changes: 6 additions & 0 deletions docs/resources/static_secret.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,10 @@ resource "akeyless_static_secret" "secret" {
- `id` (String) The ID of this resource.
- `version` (Number) The version of the secret.

## Import

Import is supported using the following syntax:

```shell
terraform import akeyless_static_secret.example /full-secret-path/and-name-in-akeyless
```
1 change: 1 addition & 0 deletions examples/resources/akeyless_auth_method/import.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
terraform import akeyless_auth_method.example /full-auth-method-path/and-name-in-akeyless
1 change: 1 addition & 0 deletions examples/resources/akeyless_auth_method_saml/import.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
terraform import akeyless_auth_method_saml.example /full-auth-method-saml-path/and-name-in-akeyless
1 change: 1 addition & 0 deletions examples/resources/akeyless_role/import.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
terraform import akeyless_role.example /full-role-path/and-name-in-akeyless
1 change: 1 addition & 0 deletions examples/resources/akeyless_static_secret/import.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
terraform import akeyless_static_secret.example /full-secret-path/and-name-in-akeyless
2 changes: 1 addition & 1 deletion version
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# Use Semantic versioning only. Please update the version number before opening a pull request.
v1.7.1
v1.7.2

0 comments on commit 07f83eb

Please sign in to comment.