types
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Index¶
- Constants
- func CtyValueString(val cty.Value) (string, error)
- func SortParameters(lists []Parameter)
- type DiagnosticSeverityString
- type Diagnostics
- type FriendlyDiagnostic
- type HCLString
- type NullHCLString
- type Parameter
- type ParameterData
- type ParameterOption
- type ParameterType
- type ParameterValidation
- type Tag
- type TagBlock
- type TagBlocks
- type Tags
- type WorkspaceOwner
- type WorkspaceOwnerRBACRole
Constants¶
const (BlockTypeParameter = "coder_parameter"BlockTypeWorkspaceTag = "coder_workspace_tag"ValidationMonotonicIncreasing = "increasing"ValidationMonotonicDecreasing = "decreasing")
@typescript-ignore BlockTypeParameter@typescript-ignore BlockTypeWorkspaceTag
const (UnknownStringValue = "??")
Variables¶
This section is empty.
Functions¶
funcCtyValueString¶
CtyValueString converts a cty.Value to a string.It supports only primitive types - bool, number, and string.As a special case, it also supports map[string]interface{} with key "value".
funcSortParameters¶
func SortParameters(lists []Parameter)
Types¶
typeDiagnosticSeverityString¶
type DiagnosticSeverityStringstring
const (DiagnosticSeverityErrorDiagnosticSeverityString = "error"DiagnosticSeverityWarningDiagnosticSeverityString = "warning")
typeDiagnostics¶
type Diagnostics hcl.Diagnostics
Diagnostics is a JSON friendly form of hcl.Diagnostics.Data is lost when doing a json marshal.
func (Diagnostics)MarshalJSON¶
func (dDiagnostics) MarshalJSON() ([]byte,error)
typeFriendlyDiagnostic¶
type FriendlyDiagnostic struct {SeverityDiagnosticSeverityString `json:"severity"`Summarystring `json:"summary"`Detailstring `json:"detail"`}
typeHCLString¶
type HCLString struct {Valuecty.Value// ValueDiags are any diagnostics that occurred// while evaluating the valueValueDiags hcl.Diagnostics// ValueExp is the underlying source expressionValueExpr hcl.Expression// Source is the literal hcl text that was parsed.// This is a best effort, it may not be available.Source *string}
@typescript-ignore HCLString
funcStringLiteral¶
func (HCLString)AsString¶
AsString is a safe function. It will always return a string.The caller should check if this value is Valid and known beforecalling this function.
func (HCLString)MarshalJSON¶
func (*HCLString)UnmarshalJSON¶
typeNullHCLString¶
typeParameter¶
type Parameter struct {ParameterData// Value is not immediately cast into a string.// Value is not required at template import, so defer// casting to a string until it is absolutely necessary.ValueHCLString `json:"value"`// Diagnostics is used to store any errors that occur during parsing// of the parameter.DiagnosticsDiagnostics `json:"diagnostics"`}
typeParameterData¶
type ParameterData struct {Namestring `json:"name"`DisplayNamestring `json:"display_name"`Descriptionstring `json:"description"`TypeParameterType `json:"type"`FormTypeprovider.ParameterFormType `json:"form_type"`Stylingany `json:"styling"`Mutablebool `json:"mutable"`DefaultValueHCLString `json:"default_value"`Iconstring `json:"icon"`Options []*ParameterOption `json:"options"`Validations []*ParameterValidation `json:"validations"`Requiredbool `json:"required"`// legacy_variable_name was removed (= 14)Orderint64 `json:"order"`Ephemeralbool `json:"ephemeral"`// Unexported fields, not always available.Source *terraform.Block `json:"-"`}
typeParameterOption¶
typeParameterType¶
type ParameterTypestring
const (ParameterTypeStringParameterType = "string"ParameterTypeNumberParameterType = "number"ParameterTypeBooleanParameterType = "bool"ParameterTypeListStringParameterType = "list(string)")
func (ParameterType)Valid¶
func (tParameterType) Valid()error
typeParameterValidation¶
type ParameterValidation struct {Errorstring `json:"validation_error"`// All validation attributes are optional.Regex *string `json:"validation_regex"`Min *int64 `json:"validation_min"`Max *int64 `json:"validation_max"`Monotonic *string `json:"validation_monotonic"`Invalid *bool `json:"validation_invalid"`}
typeWorkspaceOwner¶
type WorkspaceOwner struct {IDstring `json:"id" cty:"id"`Namestring `json:"name" cty:"name"`FullNamestring `json:"full_name" cty:"full_name"`Emailstring `json:"email" cty:"email"`SSHPublicKeystring `json:"ssh_public_key" cty:"ssh_public_key"`// SSHPrivateKey is intentionally omitted for now, due to the security risk// that exposing it poses.// SSHPrivateKey string `json:"ssh_private_key" cty:"ssh_private_key"`Groups []string `json:"groups" cty:"groups"`// SessionToken is intentionally omitted for now, due to the security risk// that exposing it poses.// SessionToken string `json:"session_token" cty:"session_token"`// OIDCAccessToken is intentionally omitted for now, due to the security risk// that exposing it poses.// OIDCAccessToken string `json:"oidc_access_token" cty:"oidc_access_token"`LoginTypestring `json:"login_type" cty:"login_type"`RBACRoles []WorkspaceOwnerRBACRole `json:"rbac_roles" cty:"rbac_roles"`}
func (*WorkspaceOwner)ToCtyValue¶
func (o *WorkspaceOwner) ToCtyValue() (cty.Value,error)