Documentation ¶
Index ¶
- func ResourceSecret() *schema.Resource
- func ResourceSecretACL() *schema.Resource
- func ResourceSecretScope() *schema.Resource
- type ACLItem
- type ACLPermission
- type KeyvaultMetadata
- type SecretACLRequest
- type SecretAclsAPI
- type SecretMetadata
- type SecretScope
- type SecretScopeACL
- type SecretScopeList
- type SecretScopesAPI
- type SecretsAPI
- type SecretsList
- type SecretsRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ResourceSecretACL ¶
ResourceSecretACL manages access to secret scopes
func ResourceSecretScope ¶
ResourceSecretScope manages secret scopes
Types ¶
type ACLItem ¶
type ACLItem struct { Principal string `json:"principal,omitempty"` Permission ACLPermission `json:"permission,omitempty"` }
ACLItem is a struct that contains information about a secret scope acl
type ACLPermission ¶
type ACLPermission string
ACLPermission is a custom type for acl permissions
const ( ACLPermissionRead ACLPermission = "READ" ACLPermissionWrite ACLPermission = "WRITE" ACLPermissionManage ACLPermission = "MANAGE" )
List of possible ACL Permissions on Databricks
type KeyvaultMetadata ¶
type KeyvaultMetadata struct { // /subscriptions/.../resourceGroups/.../providers/Microsoft.KeyVault/vaults/my-azure-kv ResourceID string `json:"resource_id"` // https://my-azure-kv.vault.azure.net/ DNSName string `json:"dns_name"` }
KeyvaultMetadata Azure Key Vault metadata wrapper
type SecretACLRequest ¶
type SecretACLRequest struct { Scope string `json:"scope,omitempty" url:"scope,omitempty"` Principal string `json:"principal,omitempty" url:"principal,omitempty"` Permission ACLPermission `json:"permission,omitempty" url:"permission,omitempty"` }
SecretACLRequest generic request for secret acls
type SecretAclsAPI ¶
type SecretAclsAPI struct {
// contains filtered or unexported fields
}
SecretAclsAPI exposes the Secret ACL API
func NewSecretAclsAPI ¶
func NewSecretAclsAPI(ctx context.Context, m any) SecretAclsAPI
NewSecretAclsAPI creates SecretAclsAPI instance from provider meta
func (SecretAclsAPI) Create ¶
func (a SecretAclsAPI) Create(scope string, principal string, permission ACLPermission) error
Create creates or overwrites the ACL associated with the given principal (user or group) on the specified scope point
func (SecretAclsAPI) Delete ¶
func (a SecretAclsAPI) Delete(scope string, principal string) error
Delete deletes the given ACL on the given scope
type SecretMetadata ¶
type SecretMetadata struct { Key string `json:"key,omitempty"` LastUpdatedTimestamp int64 `json:"last_updated_timestamp,omitempty"` }
SecretMetadata is a struct that encapsulates the metadata for a secret object in a scope
type SecretScope ¶
type SecretScope struct { Name string `json:"name" tf:"force_new"` BackendType string `json:"backend_type,omitempty" tf:"computed"` InitialManagePrincipal string `json:"initial_manage_principal,omitempty" tf:"force_new"` KeyvaultMetadata *KeyvaultMetadata `json:"keyvault_metadata,omitempty" tf:"force_new"` }
SecretScope is a struct that encapsulates the secret scope
type SecretScopeACL ¶
type SecretScopeACL struct {
Items []ACLItem `json:"items,omitempty"`
}
SecretScopeACL ...
type SecretScopeList ¶
type SecretScopeList struct {
Scopes []SecretScope `json:"scopes,omitempty"`
}
SecretScopeList holds list of secret scopes
type SecretScopesAPI ¶
type SecretScopesAPI struct {
// contains filtered or unexported fields
}
SecretScopesAPI exposes the Secret Scopes API
func NewSecretScopesAPI ¶
func NewSecretScopesAPI(ctx context.Context, m any) SecretScopesAPI
NewSecretScopesAPI creates SecretScopesAPI instance from provider meta
func (SecretScopesAPI) Create ¶
func (a SecretScopesAPI) Create(s SecretScope) error
Create creates a new secret scope
func (SecretScopesAPI) Delete ¶
func (a SecretScopesAPI) Delete(scope string) error
Delete deletes a secret scope
func (SecretScopesAPI) List ¶
func (a SecretScopesAPI) List() ([]SecretScope, error)
List lists all secret scopes available in the workspace
func (SecretScopesAPI) Read ¶
func (a SecretScopesAPI) Read(scopeName string) (SecretScope, error)
Read will return the metadata for the secret scope
type SecretsAPI ¶
type SecretsAPI struct {
// contains filtered or unexported fields
}
SecretsAPI exposes the Secrets API
func NewSecretsAPI ¶
func NewSecretsAPI(ctx context.Context, m any) SecretsAPI
NewSecretsAPI creates SecretsAPI instance from provider meta
func (SecretsAPI) Create ¶
func (a SecretsAPI) Create(stringValue, scope, key string) error
Create creates or modifies a string secret depends on the type of scope backend
func (SecretsAPI) Delete ¶
func (a SecretsAPI) Delete(scope, key string) error
Delete deletes a secret depends on the type of scope backend
func (SecretsAPI) List ¶
func (a SecretsAPI) List(scope string) ([]SecretMetadata, error)
List lists the secret keys that are stored at this scope
func (SecretsAPI) Read ¶
func (a SecretsAPI) Read(scope string, key string) (SecretMetadata, error)
Read returns the metadata for the secret and not the contents of the secret
type SecretsList ¶
type SecretsList struct {
Secrets []SecretMetadata `json:"secrets,omitempty"`
}
SecretsList ...
type SecretsRequest ¶
type SecretsRequest struct { StringValue string `json:"string_value,omitempty" mask:"true"` Scope string `json:"scope,omitempty"` Key string `json:"key,omitempty"` }
SecretsRequest ...