types

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attachment added in v0.9.0

type Attachment struct {
	ID           string `json:"id" header:"ID"`
	Name         string `json:"name,omitempty" header:"NAME"`
	Uploaded     bool   `json:"uploaded,omitempty" header:"UPLOADED"`
	UploadURL    string `json:"upload_url,omitempty" header:"UPLOAD_URL" show:"noshow,nolist"`
	DownloadURL  string `json:"download_url,omitempty" header:"DOWNLOAD_URL" show:"nolist"`
	ResourceType string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
}

Attachment stores an IMCO Attachment item

type BootstrappingAppliedConfiguration added in v0.8.0

type BootstrappingAppliedConfiguration struct {
	StartedAt             string `json:"started_at,omitempty" header:"STARTED_AT"`
	FinishedAt            string `json:"finished_at,omitempty" header:"FINISHED_AT"`
	PolicyfileRevisionIDs string `json:"policyfile_revision_ids,omitempty" header:"POLICY_FILE_REVISION_IDS" show:"nolist"`
	AttributeRevisionID   string `json:"attribute_revision_id,omitempty" header:"ATTRIBUTE_REVISION_ID"`
}

type BootstrappingConfiguration added in v0.8.0

type BootstrappingConfiguration struct {
	Policyfiles         []BootstrappingPolicyfile `json:"policyfiles,omitempty" header:"POLICY_FILES" show:"nolist"`
	Attributes          map[string]interface{}    `json:"attributes,omitempty" header:"ATTRIBUTES" show:"nolist"`
	AttributeRevisionID string                    `json:"attribute_revision_id,omitempty" header:"ATTRIBUTE_REVISION_ID"`
}

type BootstrappingContinuousReport added in v0.8.0

type BootstrappingContinuousReport struct {
	Stdout string `json:"stdout" header:"STDOUT"`
}

type BootstrappingPolicyfile added in v0.8.0

type BootstrappingPolicyfile struct {
	ID          string `json:"id,omitempty" header:"ID"`
	RevisionID  string `json:"revision_id,omitempty" header:"REVISION_ID"`
	DownloadURL string `json:"download_url,omitempty" header:"DOWNLOAD_URL"`
}

type CloudAccount

type CloudAccount struct {
	ID                           string    `json:"id" header:"ID"`
	Name                         string    `json:"name" header:"NAME"`
	CloudProviderID              string    `json:"cloud_provider_id" header:"CLOUD_PROVIDER_ID"`
	CloudProviderName            string    `header:"CLOUD_PROVIDER_NAME"`
	SupportsImporting            bool      `json:"supports_importing" header:"SUPPORTS_IMPORTING" show:"nolist"`
	SupportsImportingVPCs        bool      `json:"supports_importing_vpcs" header:"SUPPORTS_IMPORTING_VPCS" show:"nolist"`
	SupportsImportingFloatingIPs bool      `json:"supports_importing_floating_ips" header:"SUPPORTS_IMPORTING_FLOATING_IPS" show:"nolist"`
	LastDiscoveredAt             time.Time `json:"last_discovered_at" header:"LAST_DISCOVERED" show:"nolist"`
	LastDiscoveredFailedAt       time.Time `json:"last_discovery_failed_at" header:"LAST_DISCOVERED_FAILED" show:"nolist"`
	ResourceType                 string    `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
}

type CloudProvider

type CloudProvider struct {
	ID   string `json:"id" header:"ID"`
	Name string `json:"name" header:"NAME"`
}

type CookbookVersion added in v0.9.0

type CookbookVersion struct {
	ID                string   `json:"id" header:"ID"`
	Name              string   `json:"name" header:"NAME"`
	Version           string   `json:"version" header:"VERSION"`
	State             string   `json:"state" header:"STATE"`
	RevisionID        string   `json:"revision_id,omitempty" header:"REVISION_ID"`
	Description       string   `json:"description" header:"DESCRIPTION"`
	Recipes           []string `json:"recipes"  header:"RECIPES" show:"nolist"`
	ResourceType      string   `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	PubliclyAvailable bool     `json:"publicly_available" header:"PUBLICLY_AVAILABLE" show:"nolist"`
	GlobalLegacy      bool     `json:"global_legacy" header:"GLOBAL_LEGACY" show:"nolist"`
	UploadURL         string   `json:"upload_url" header:"UPLOAD_URL" show:"noshow,nolist"`
	ErrorMessage      string   `json:"error_message" header:"ERROR_MESSAGE" show:"nolist"`
	LabelableFields
}

type DispatcherScript added in v0.9.0

type DispatcherScript struct {
	Code            string   `json:"code"`
	UUID            string   `json:"uuid"`
	AttachmentPaths []string `json:"attachment_paths"`
}

type Event

type Event struct {
	ID          string    `json:"id" header:"ID"`
	Timestamp   time.Time `json:"timestamp" header:"TIMESTAMP"`
	Level       string    `json:"level" header:"LEVEL"`
	Header      string    `json:"header" header:"HEADER"`
	Description string    `json:"description" header:"DESCRIPTION"`
}

Event stores an Concerto event item

type Firewall added in v0.9.0

type Firewall struct {
	Profile Policy `json:"firewall_profile"`
}

type FirewallProfile

type FirewallProfile struct {
	ID           string `json:"id" header:"ID"`
	Name         string `json:"name,omitempty" header:"NAME"`
	Description  string `json:"description,omitempty" header:"DESCRIPTION"`
	Default      bool   `json:"default,omitempty" header:"DEFAULT"`
	Rules        []Rule `json:"rules,omitempty" header:"RULES" show:"nolist"`
	ResourceType string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	LabelableFields
}

func (*FirewallProfile) ConvertFlagParamsToRules added in v0.9.0

func (fp *FirewallProfile) ConvertFlagParamsToRules(rulesIn string) error

ConvertFlagParamsToRules converts received input rules parameters into a Firewall Profile rules array

type FloatingIP added in v0.9.0

type FloatingIP struct {
	ID               string `json:"id" header:"ID"`
	Name             string `json:"name,omitempty" header:"NAME"`
	Address          string `json:"address,omitempty" header:"ADDRESS"`
	State            string `json:"state,omitempty" header:"STATE"`
	CloudAccountID   string `json:"cloud_account_id,omitempty" header:"CLOUD_ACCOUNT_ID"`
	RealmID          string `json:"realm_id,omitempty" header:"REALM_ID"`
	AttachedServerID string `json:"attached_server_id,omitempty" header:"ATTACHED_SERVER_ID"`
	ResourceType     string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	Brownfield       bool   `json:"brownfield,omitempty" header:"BROWNFIELD" show:"nolist,noshow"`
	LabelableFields
}

FloatingIP stores an IMCO Floating IP item

type GenericImage

type GenericImage struct {
	ID   string `json:"id" header:"ID"`
	Name string `json:"name" header:"NAME"`
}

type Label added in v0.8.0

type Label struct {
	ID           string `json:"id" header:"ID"`
	Name         string `json:"name" header:"NAME"`
	ResourceType string `json:"resource_type" header:"RESOURCE_TYPE"`
	Namespace    string `json:"namespace" header:"NAMESPACE" show:"nolist"`
	Value        string `json:"value" header:"VALUE" show:"nolist"`
}

type Labelable added in v0.8.0

type Labelable interface {
	FilterByLabelIDs(labelIDs []string) bool
	AssignLabelIDs(labelIDs []string)
	FillInLabelNames(labelNamesByID map[string]string)
}

type LabelableFields added in v0.8.0

type LabelableFields struct {
	LabelIDs []string `json:"label_ids" header:"LABEL_IDS" show:"nolist,noshow"`
	Labels   []string `json:"labels" header:"LABELS"`
}

func (*LabelableFields) AssignLabelIDs added in v0.8.0

func (lf *LabelableFields) AssignLabelIDs(labelIDs []string)

func (*LabelableFields) FillInLabelNames added in v0.8.0

func (lf *LabelableFields) FillInLabelNames(labelNamesByID map[string]string)

func (*LabelableFields) FilterByLabelIDs added in v0.8.0

func (lf *LabelableFields) FilterByLabelIDs(labelIDs []string) bool

type LabeledResource added in v0.8.0

type LabeledResource struct {
	ID           string `json:"id" header:"ID"`
	ResourceType string `json:"resource_type" header:"RESOURCE_TYPE"`
}

type Location

type Location struct {
	ID   string `json:"id" header:"ID"`
	Name string `json:"name" header:"NAME"`
}

type Policy added in v0.9.0

type Policy struct {
	Rules       []PolicyRule `json:"rules"`
	Md5         string       `json:"md5,omitempty"`
	ActualRules []PolicyRule `json:"actual_rules,omitempty"`
}

func (*Policy) CheckPolicyRule added in v0.9.0

func (p *Policy) CheckPolicyRule(rule PolicyRule) bool

CheckPolicyRule checks if rule belongs to Policy

type PolicyRule added in v0.9.0

type PolicyRule struct {
	Name     string `json:"name,omitempty" header:"NAME" show:"nolist"`
	Cidr     string `json:"cidr_ip" header:"CIDR"`
	Protocol string `json:"ip_protocol" header:"PROTOCOL"`
	MinPort  int    `json:"min_port" header:"MIN"`
	MaxPort  int    `json:"max_port" header:"MAX"`
}

type PollingCommand

type PollingCommand struct {
	ID       string `json:"id" header:"ID"`
	Script   string `json:"script" header:"SCRIPT"`
	Stdout   string `json:"stdout" header:"STDOUT"`
	Stderr   string `json:"stderr" header:"STDERR"`
	ExitCode int    `json:"exit_code" header:"EXIT_CODE"`
}

type PollingContinuousReport

type PollingContinuousReport struct {
	Stdout string `json:"stdout" header:"STDOUT"`
}

type PollingPing

type PollingPing struct {
	PendingCommands bool `json:"pending_commands" header:"PENDING_COMMANDS"`
}

type RequiredCredentials

type RequiredCredentials interface{}

type Rule

type Rule struct {
	Protocol string `json:"ip_protocol" header:"IP_PROTOCOL"`
	MinPort  int    `json:"min_port" header:"MIN_PORT"`
	MaxPort  int    `json:"max_port" header:"MAX_PORT"`
	CidrIP   string `json:"source" header:"SOURCE"`
}

type SSHProfile

type SSHProfile struct {
	ID           string `json:"id" header:"ID"`
	Name         string `json:"name" header:"NAME"`
	PublicKey    string `json:"public_key" header:"PUBLIC_KEY"`
	PrivateKey   string `json:"private_key" header:"PRIVATE_KEY" show:"nolist"`
	ResourceType string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	LabelableFields
}

type Script

type Script struct {
	ID           string   `json:"id" header:"ID"`
	Name         string   `json:"name" header:"NAME"`
	Description  string   `json:"description" header:"DESCRIPTION"`
	Code         string   `json:"code" header:"CODE" show:"nolist"`
	Parameters   []string `json:"parameters" header:"PARAMETERS"`
	ResourceType string   `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	LabelableFields
}

Script holds script data

type ScriptChar

type ScriptChar struct {
	ResourceType    string                 `json:"resource_type" header:"RESOURCE_TYPE" show:"noshow,nolist"`
	ID              string                 `json:"id" header:"ID"`
	Type            string                 `json:"type" header:"TYPE"`
	ParameterValues map[string]interface{} `json:"parameter_values" header:"PARAMETER_VALUES"`
	TemplateID      string                 `json:"template_id" header:"TEMPLATE_ID"`
	ScriptID        string                 `json:"script_id" header:"SCRIPT_ID"`
	ExecutionOrder  int                    `json:"execution_order" header:"EXECUTION_ORDER" show:"noshow,nolist"`
}

type ScriptCharacterization added in v0.9.0

type ScriptCharacterization struct {
	Order      int               `json:"execution_order"`
	UUID       string            `json:"uuid"`
	Script     DispatcherScript  `json:"script"`
	Parameters map[string]string `json:"parameter_values"`
}

type ScriptConclusion added in v0.9.0

type ScriptConclusion struct {
	UUID       string `json:"script_characterization_id"`
	Output     string `json:"output"`
	ExitCode   int    `json:"exit_code"`
	StartedAt  string `json:"started_at"`
	FinishedAt string `json:"finished_at"`
}

type Server

type Server struct {
	ID                string `json:"id" header:"ID"`
	Name              string `json:"name" header:"NAME"`
	Fqdn              string `json:"fqdn" header:"FQDN"`
	State             string `json:"state" header:"STATE"`
	PublicIP          string `json:"public_ip" header:"PUBLIC_IP"`
	PrivateIP         string `json:"private_ip,omitempty" header:"PRIVATE_IP"`
	TemplateID        string `json:"template_id" header:"TEMPLATE_ID"`
	ServerPlanID      string `json:"server_plan_id" header:"SERVER_PLAN_ID"`
	CloudAccountID    string `json:"cloud_account_id" header:"CLOUD_ACCOUNT_ID"`
	SSHProfileID      string `json:"ssh_profile_id" header:"SSH_PROFILE_ID"`
	FirewallProfileID string `json:"firewall_profile_id" header:"FIREWALL_PROFILE_ID"`
	ServerArrayID     string `json:"server_array_id,omitempty" header:"SERVER_ARRAY_ID" show:"nolist"`
	SubnetID          string `json:"subnet_id,omitempty" header:"SUBNET_ID" show:"nolist"`
	VpcID             string `json:"vpc_id,omitempty" header:"VPC_ID" show:"nolist"`
	Privateness       bool   `json:"privateness,omitempty" header:"PRIVATENESS" show:"nolist"`
	ResourceType      string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	LabelableFields
}

type ServerArray added in v0.9.0

type ServerArray struct {
	ID                string `json:"id" header:"ID"`
	Name              string `json:"name" header:"NAME"`
	State             string `json:"state" header:"STATE"`
	Size              int    `json:"size" header:"SIZE"`
	TemplateID        string `json:"template_id" header:"TEMPLATE_ID"`
	CloudAccountID    string `json:"cloud_account_id" header:"CLOUD_ACCOUNT_ID"`
	ServerPlanID      string `json:"server_plan_id" header:"SERVER_PLAN_ID"`
	FirewallProfileID string `json:"firewall_profile_id" header:"FIREWALL_PROFILE_ID"`
	SSHProfileID      string `json:"ssh_profile_id" header:"SSH_PROFILE_ID"`
	SubnetID          string `json:"subnet_id,omitempty" header:"SUBNET_ID" show:"nolist"`
	VpcID             string `json:"vpc_id,omitempty" header:"VPC_ID" show:"nolist"`
	Privateness       bool   `json:"privateness,omitempty" header:"PRIVATENESS" show:"nolist"`
	ResourceType      string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	LabelableFields
}

type ServerPlan

type ServerPlan struct {
	ID                string  `json:"id" header:"ID"`
	Name              string  `json:"name" header:"NAME"`
	Memory            int     `json:"memory" header:"MEMORY"`
	CPUs              float32 `json:"cpus" header:"CPUS"`
	Storage           int     `json:"storage" header:"STORAGE"`
	LocationID        string  `json:"location_id" header:"LOCATION_ID"`
	LocationName      string  `json:"location_name" header:"LOCATION_NAME"`
	CloudProviderID   string  `json:"cloud_provider_id" header:"CLOUD_PROVIDER_ID"`
	CloudProviderName string  `json:"cloud_provider_name" header:"CLOUD_PROVIDER_NAME"`
}

type StoragePlan added in v0.9.0

type StoragePlan struct {
	ID                  string `json:"id" header:"ID"`
	Name                string `json:"name" header:"NAME"`
	MinSize             int    `json:"min_size,omitempty" header:"MIN_SIZE"`
	MaxSize             int    `json:"max_size,omitempty" header:"MAX_SIZE"`
	CloudProviderID     string `json:"cloud_provider_id,omitempty" header:"CLOUD_PROVIDER_ID"`
	CloudProviderName   string `header:"CLOUD_PROVIDER_NAME"`
	LocationID          string `json:"location_id,omitempty" header:"LOCATION_ID"`
	LocationName        string `header:"LOCATION_NAME"`
	RealmID             string `json:"realm_id,omitempty" header:"REALM_ID"`
	RealmProviderName   string `json:"realm_provider_name,omitempty" header:"REALM_PROVIDER_NAME"`
	FlavourProviderName string `json:"flavour_provider_name,omitempty" header:"FLAVOUR_PROVIDER_NAME"`
	Deprecated          bool   `json:"deprecated,omitempty" header:"DEPRECATED" show:"nolist,noshow"`
	ResourceType        string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
}

type Subnet added in v0.9.0

type Subnet struct {
	ID                     string `json:"id" header:"ID"`
	Name                   string `json:"name,omitempty" header:"NAME"`
	CIDR                   string `json:"cidr,omitempty" header:"CIDR"`
	State                  string `json:"state,omitempty" header:"STATE"`
	Type                   string `json:"type,omitempty" header:"STATE"`
	VpcID                  string `json:"vpc_id,omitempty" header:"VPC_ID"`
	ServerCreationDisabled bool   `json:"server_creation_disabled,omitempty" header:"SERVER_CREATION_DISABLED" show:"nolist,noshow"`
	ResourceType           string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	Brownfield             bool   `json:"brownfield,omitempty" header:"BROWNFIELD" show:"nolist,noshow"`
}

Subnet stores an IMCO VPC Subnet item

type Template

type Template struct {
	ID                      string                 `json:"id,omitempty" header:"ID"`
	Name                    string                 `json:"name,omitempty" header:"NAME"`
	GenericImageID          string                 `json:"generic_image_id,omitempty" header:"GENERIC_IMAGE_ID"`
	RunList                 []string               `json:"run_list,omitempty" header:"RUN_LIST" show:"nolist"`
	ConfigurationAttributes map[string]interface{} `json:"configuration_attributes,omitempty" header:"CONFIGURATION_ATTRIBUTES" show:"nolist"`
	ResourceType            string                 `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	CookbookVersions        cookbookVersionsMap    `json:"cookbook_versions,omitempty" header:"COOKBOOK_VERSIONS" show:"nolist"`
	State                   string                 `json:"state" header:"STATE" show:"nolist"`
	LabelableFields
}

Template stores blueprint templates

func (*Template) FillInCookbookVersionComposite added in v0.9.0

func (t *Template) FillInCookbookVersionComposite(customCookbookVersionsByVersionID map[string]string)

FillInCookbookVersionComposite resolves adequate cookbook version from version_id

type TemplateScript

type TemplateScript struct {
	ID              string                 `json:"id" header:"ID"`
	Type            string                 `json:"type" header:"TYPE"`
	ExecutionOrder  int                    `json:"execution_order" header:"EXECUTION_ORDER"`
	TemplateID      string                 `json:"template_id" header:"TEMPLATE_ID"`
	ScriptID        string                 `json:"script_id" header:"SCRIPT_ID"`
	ParameterValues map[string]interface{} `json:"parameter_values" header:"PARAMETER_VALUES"`
}

TemplateScript stores a templates' script info

type TemplateScriptCredentials

type TemplateScriptCredentials interface{}

TemplateScriptCredentials stores credentials to servers

type TemplateServer

type TemplateServer struct {
	ID                string `json:"id"  header:"ID"`
	Name              string `json:"name" header:"NAME"`
	Fqdn              string `json:"fqdn" header:"FQDN"`
	State             string `json:"state" header:"STATE"`
	PublicIP          string `json:"public_ip" header:"PUBLIC_IP"`
	TemplateID        string `json:"template_id" header:"TEMPLATE_ID"`
	ServerPlanID      string `json:"server_plan_id" header:"SERVER_PLAN_ID"`
	SSHProfileID      string `json:"ssh_profile_id" header:"SSH_PROFILE_ID"`
	FirewallProfileID string `json:"firewall_profile_id" header:"FIREWALL_PROFILE_ID"`
}

TemplateServer stores servers associated with the template

type Volume added in v0.9.0

type Volume struct {
	ID               string `json:"id" header:"ID"`
	Name             string `json:"name" header:"NAME"`
	Size             int    `json:"size" header:"SIZE"`
	State            string `json:"state" header:"STATE"`
	Device           string `json:"device" header:"DEVICE"`
	StoragePlanID    string `json:"storage_plan_id,omitempty" header:"STORAGE_PLAN_ID"`
	CloudAccountID   string `json:"cloud_account_id,omitempty" header:"CLOUD_ACCOUNT_ID"`
	RealmID          string `json:"realm_id,omitempty" header:"REALM_ID"`
	AttachedServerID string `json:"attached_server_id,omitempty" header:"ATTACHED_SERVER_ID"`
	Brownfield       bool   `json:"brownfield,omitempty" header:"BROWNFIELD" show:"nolist,noshow"`
	ResourceType     string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	LabelableFields
}

type Vpc added in v0.9.0

type Vpc struct {
	ID                 string   `json:"id" header:"ID"`
	Name               string   `json:"name,omitempty" header:"NAME"`
	CIDR               string   `json:"cidr,omitempty" header:"CIDR"`
	State              string   `json:"state,omitempty" header:"STATE"`
	CloudAccountID     string   `json:"cloud_account_id,omitempty" header:"CLOUD_ACCOUNT_ID"`
	RealmProviderName  string   `json:"realm_provider_name,omitempty" header:"REALM_PROVIDER_NAME"`
	HasVPN             bool     `json:"has_vpn,omitempty" header:"HAS_VPN" show:"nolist,noshow"`
	AllowedSubnetTypes []string `json:"allowed_subnet_types,omitempty" header:"ALLOWED_SUBNET_TYPES"`
	ResourceType       string   `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
	Brownfield         bool     `json:"brownfield,omitempty" header:"BROWNFIELD" show:"nolist,noshow"`
	LabelableFields
}

Vpc stores an IMCO VPC item

type Vpn added in v0.9.0

type Vpn struct {
	ID           string   `json:"id" header:"ID"`
	State        string   `json:"state,omitempty" header:"STATE"`
	VpcID        string   `json:"vpc_id,omitempty" header:"VPC_ID"`
	VpnPlanID    string   `json:"vpn_plan_id,omitempty" header:"VPN_PLAN_ID"`
	PublicIP     string   `json:"public_ip,omitempty" header:"PUBLIC_IP"`
	ExposedCIDRs []string `json:"exposed_cidrs,omitempty" header:"EXPOSED_CIDRS"`
	ResourceType string   `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
}

Vpn stores an IMCO VPN item

type VpnPlan added in v0.9.0

type VpnPlan struct {
	ID           string `json:"id" header:"ID"`
	Name         string `json:"name,omitempty" header:"NAME"`
	Active       string `json:"active_active,omitempty" header:"ACTIVE"`
	RemoteID     string `json:"remote_id,omitempty" header:"REMOTE_ID"`
	ResourceType string `json:"resource_type" header:"RESOURCE_TYPE" show:"nolist"`
}

VpnPlan stores an IMCO VPN Plan item

type WizardApp

type WizardApp struct {
	ID                  string                 `json:"id" header:"ID"`
	Name                string                 `json:"name" header:"NAME"`
	FlavourRequirements map[string]interface{} `json:"flavour_requirements" header:"FLAVOUR_REQUIREMENTS"`
	GenericImageID      string                 `json:"generic_image_id" header:"GENERIC_IMAGE_ID"`
}

Jump to

Keyboard shortcuts

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