Documentation
¶
Overview ¶
Helpers for dealing with file paths and their contents
Originally from Terraform; see https://www.terraform.io/docs/extend/guides/v2-upgrade-guide.html#removal-of-helper-pathorcontents-package
Index ¶
Constants ¶
View Source
const ( // IDKey is used for common SDK ID resource attribute IDKey = "id" // NameKey is used for common "name" resource attribute NameKey = "name" // DescriptionKey is used for common "description" resource attribute DescriptionKey = "description" // ScopeIdKey is used for common "scope_id" resource attribute ScopeIdKey = "scope_id" // TypeKey is used for common "type" resource attribute TypeKey = "type" // HostCatalogIdKey is used for common "host_catalog_id" resource attribute HostCatalogIdKey = "host_catalog_id" // AuthMethodIdKey is used for common "auth_method_id" resource attribute AuthMethodIdKey = "auth_method_id" // PluginIdKey is used for common "plugin_id" resource attribute PluginIdKey = "plugin_id" // PluginNameKey is used for common "plugin_name" resource attribute PluginNameKey = "plugin_name" // AttributesJsonKey is used for setting attributes and corresponds to the // API "attributes" key AttributesJsonKey = "attributes_json" // SecretsJsonKey is used for setting secrets and corresponds to the API // "secrets" key SecretsJsonKey = "secrets_json" // SecretsHmacKey is a read-only key used for ensuring we detect if secrets // have changed SecretsHmacKey = "secrets_hmac" // PreferredEndpointsKey is used for setting preferred endpoints PreferredEndpointsKey = "preferred_endpoints" // SyncIntervalSecondsKey is used for setting the interval seconds SyncIntervalSecondsKey = "sync_interval_seconds" )
Variables ¶
This section is empty.
Functions ¶
func ReadPathOrContents ¶
If the argument is a path, Read loads it and returns the contents, otherwise the argument is assumed to be the desired contents and is simply returned.
The boolean second return value can be called `wasPath` - it indicates if a path was detected and a file loaded.
Types ¶
This section is empty.
Source Files
¶
- const.go
- pathorcontents.go
- provider.go
- resource_account.go
- resource_account_oidc.go
- resource_account_password.go
- resource_auth_method.go
- resource_auth_method_oidc.go
- resource_auth_method_password.go
- resource_credential_json.go
- resource_credential_library_vault.go
- resource_credential_ssh_private_key.go
- resource_credential_store_static.go
- resource_credential_store_vault.go
- resource_credential_username_password.go
- resource_group.go
- resource_host_catalog_plugin.go
- resource_host_catalog_static.go
- resource_host_set_plugin.go
- resource_host_set_static.go
- resource_host_static.go
- resource_managed_group.go
- resource_role.go
- resource_scope.go
- resource_target.go
- resource_user.go
Click to show internal directories.
Click to hide internal directories.