Skip to content

Commit

Permalink
fix docs, log msg and remove elem type
Browse files Browse the repository at this point in the history
  • Loading branch information
fairclothjm committed Mar 25, 2024
1 parent 71fa452 commit bd75a40
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
5 changes: 1 addition & 4 deletions vault/data_source_namespace.go
Expand Up @@ -42,9 +42,6 @@ func namespaceDataSource() *schema.Resource {
Type: schema.TypeMap,
Computed: true,
Description: "Metadata associated with this namespace.",
Elem: &schema.Schema{
Type: schema.TypeString,
},
},
},
}
Expand All @@ -60,7 +57,7 @@ func namespaceDataSourceRead(ctx context.Context, d *schema.ResourceData, meta i
if v, ok := d.GetOk(consts.FieldPath); ok {
path = v.(string)
} else {
log.Printf("[DEBUG] namespace not set in config, returning current Vault client namespace")
log.Printf("[DEBUG] namespace path not set in config, returning current Vault client namespace")
providerNS := client.Namespace()
return namespaceDataSourceReadCurrent(d, providerNS)
}
Expand Down
9 changes: 5 additions & 4 deletions website/docs/d/namespace.html.md
@@ -1,14 +1,14 @@
---
layout: "vault"
page_title: "Vault: vault_namespace data souece"
page_title: "Vault: vault_namespace data source"
sidebar_current: "docs-vault-datasource-namespace"
description: |-
Reads namespace information from Vault
---

# vault\_namespace

Lookup a [Namespaces](https://www.vaultproject.io/docs/enterprise/namespaces/index.html) from Vault or from the provider configuration.
Lookup a [Namespace](https://developer.hashicorp.com/vault/docs/enterprise/namespaces) from Vault or from the provider configuration.

**Note** this feature is available only with Vault Enterprise.

Expand Down Expand Up @@ -53,10 +53,11 @@ The following arguments are supported:
* `namespace` - (Optional) The namespace to provision the resource in.
The value should not contain leading or trailing forward slashes.
The `namespace` is always relative to the provider's configured [namespace](/docs/providers/vault#namespace).
*Available only for Vault Enterprise*.

* `path` - (Optional) The path of the namespace. Must not have a trailing `/`.
If not specified or empty, path attributes are set for the current namespace based on the `namespace` arguments of the provider and this data source. Other than path related attributes will be `null` in this case.
If not specified or empty, path attributes are set for the current namespace
based on the `namespace` arguments of the provider and this data source.
Other path related attributes will be empty in this case.

## Attributes Reference

Expand Down

0 comments on commit bd75a40

Please sign in to comment.