common

package
v1.4.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 22, 2025 License: MPL-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FunctionNodeNameValidators []validator.String = []validator.String{
		stringvalidator.LengthBetween(3, 80),
		stringvalidator.RegexMatches(
			regexp.MustCompile(`^[A-Za-z0-9\-\_ ]*$`),
			"value must contain only lowercase/uppercase alphanumeric characters, \"-\", or \"_\"",
		),
	}
	LogLevelValidator validator.String = stringvalidator.OneOf(
		string(api.LogLevelDebug),
		string(api.LogLevelError),
		string(api.LogLevelInfo),
		string(api.LogLevelWarning),
	)
	NameValidators []validator.String = []validator.String{
		stringvalidator.LengthBetween(3, 80),
		stringvalidator.RegexMatches(
			regexp.MustCompile(`^[A-Za-z0-9\-\_\.\: ]*$`),
			"value must contain only lowercase/uppercase alphanumeric characters, \"-\", \"_\", \":\", or \".\"",
		),
	}
	PortValidator     validator.Int64  = int64validator.Between(1024, 65535)
	ProtocolValidator validator.String = stringvalidator.OneOf(
		string(api.ProtocolSctp),
		string(api.ProtocolTcp),
		string(api.ProtocolUdp),
	)
	RequirementsValidator validator.Set = setvalidator.ValueStringsAre(
		stringvalidator.LengthAtLeast(1),
	)
	SystemNameValidator validator.String = stringvalidator.RegexMatches(
		regexp.MustCompile(`^echo\..*$`),
		"value must begin with \"echo.\"",
	)
	NotSystemNameValidator validator.String = validators.Not(SystemNameValidator)
)

Functions

func AwsCredentialsAttrTypes

func AwsCredentialsAttrTypes() map[string]attr.Type

func AwsCredentialsAttrValues

func AwsCredentialsAttrValues(
	accessKeyId string,
	expiration string,
	secretAccessKey string,
	sessionToken string,
) map[string]attr.Value

func AwsCredentialsSchema

func AwsCredentialsSchema() map[string]dsschema.Attribute

func CognitoCredentialsAttrTypes

func CognitoCredentialsAttrTypes() map[string]attr.Type

func CognitoCredentialsAttrValues

func CognitoCredentialsAttrValues(
	clientId string,
	password string,
	userPoolId string,
	username string,
) map[string]attr.Value

func CognitoCredentialsDataSourceSchema added in v1.4.0

func CognitoCredentialsDataSourceSchema() map[string]dataSourceSchema.Attribute

func CognitoCredentialsResourceSchema added in v1.4.0

func CognitoCredentialsResourceSchema() map[string]resourceSchema.Attribute

Types

type AwsCredentialsModel

type AwsCredentialsModel struct {
	AccessKeyId     types.String `tfsdk:"access_key_id"`
	Expiration      types.String `tfsdk:"expiration"`
	SecretAccessKey types.String `tfsdk:"secret_access_key"`
	SessionToken    types.String `tfsdk:"session_token"`
}

type CognitoCredentialsModel

type CognitoCredentialsModel struct {
	ClientId   types.String `tfsdk:"client_id"`
	Password   types.String `tfsdk:"password"`
	UserPoolId types.String `tfsdk:"user_pool_id"`
	Username   types.String `tfsdk:"username"`
}

type Config

type Config struct {
	// contains filtered or unexported fields
}

Config represents a UTF-8 string value.

func ConfigNull added in v0.0.4

func ConfigNull() Config

ConfigNull creates a Config with a null value. Determine whether the value is null via the Config type IsNull method.

func ConfigUnknown added in v0.0.4

func ConfigUnknown() Config

ConfigUnknown creates a Config with an unknown value. Determine whether the value is unknown via the Config type IsUnknown method.

func ConfigValue added in v0.0.4

func ConfigValue(value string) Config

ConfigValue creates a Config with a known value. Access the value via the Config type ValueConfig method.

Setting the deprecated String type Null, Unknown, or Value fields after creating a String with this function has no effect.

func (Config) Equal

func (c Config) Equal(other attr.Value) bool

Equal returns true if `other` is a Config and has the same value as `c`.

func (Config) IsNull

func (c Config) IsNull() bool

IsNull returns true if the Config represents a null value.

func (Config) IsUnknown

func (c Config) IsUnknown() bool

IsUnknown returns true if the Config represents a currently unknown value.

func (Config) String

func (c Config) String() string

String returns a human-readable representation of the Config value. The string returned here is not protected by any compatibility guarantees, and is intended for logging and error reporting.

func (Config) ToStringValue added in v0.0.7

func (c Config) ToStringValue(ctx context.Context) (types.String, diag.Diagnostics)

func (Config) ToTerraformValue

func (c Config) ToTerraformValue(_ context.Context) (tftypes.Value, error)

ToTerraformValue returns the data contained in the *Config as a tftypes.Value.

func (Config) Type

func (c Config) Type(_ context.Context) attr.Type

Type returns a ConfigType.

func (Config) ValueConfig added in v0.0.4

func (c Config) ValueConfig() string

ValueConfig returns the known config value. If Config is null or unknown, returns "".

type ConfigType

type ConfigType struct{}

func (ConfigType) ApplyTerraform5AttributePathStep

func (ct ConfigType) ApplyTerraform5AttributePathStep(step tftypes.AttributePathStep) (interface{}, error)

func (ConfigType) Equal

func (ct ConfigType) Equal(o attr.Type) bool

func (ConfigType) String

func (ct ConfigType) String() string

func (ConfigType) TerraformType

func (ct ConfigType) TerraformType(ctx context.Context) tftypes.Type

func (ConfigType) Validate

func (ct ConfigType) Validate(ctx context.Context, in tftypes.Value, path path.Path) diag.Diagnostics

func (ConfigType) ValueFromString added in v0.0.7

func (ConfigType) ValueFromTerraform

func (ct ConfigType) ValueFromTerraform(ctx context.Context, in tftypes.Value) (attr.Value, error)

func (ConfigType) ValueType

func (ct ConfigType) ValueType(ctx context.Context) attr.Value

type ProviderData

type ProviderData struct {
	// graphql client used to make API calls to EchoStream
	Client graphql.Client

	//EchoStream Tenant that this provider is for
	Tenant string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL