Documentation ¶
Index ¶
- func ActionTypeStrings() []string
- func IsNil(i interface{}) bool
- type ActionType
- type AutoDeployAction
- type CommunityActionTemplate
- type CommunityActionTemplateService
- func (s *CommunityActionTemplateService) Get(communityActionTemplatesQuery CommunityActionTemplatesQuery) (*resources.Resources[*CommunityActionTemplate], error)
- func (s *CommunityActionTemplateService) GetAll() ([]*CommunityActionTemplate, error)
- func (s *CommunityActionTemplateService) GetByID(id string) (*CommunityActionTemplate, error)
- func (s *CommunityActionTemplateService) GetByIDs(ids []string) ([]*CommunityActionTemplate, error)
- func (s *CommunityActionTemplateService) GetByName(name string) (*CommunityActionTemplate, error)
- func (s *CommunityActionTemplateService) Install(resource CommunityActionTemplate) (*CommunityActionTemplate, error)
- func (s *CommunityActionTemplateService) Update(resource CommunityActionTemplate) (*CommunityActionTemplate, error)
- type CommunityActionTemplatesQuery
- type CreateReleaseAction
- type DeployLatestReleaseAction
- type DeployNewReleaseAction
- type ITriggerAction
- type ProjectTriggerAction
- type RunRunbookAction
- type VersionControlReference
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ActionTypeStrings ¶ added in v2.39.0
func ActionTypeStrings() []string
ActionTypeStrings returns a slice of all String values of the enum
Types ¶
type ActionType ¶
type ActionType int
const ( AutoDeploy ActionType = iota DeployLatestRelease DeployNewRelease RunRunbook CreateRelease )
func ActionTypeString ¶
func ActionTypeString(s string) (ActionType, error)
ActionTypeString retrieves an enum value from the enum constants string name. Throws an error if the param is not part of the enum.
func ActionTypeValues ¶
func ActionTypeValues() []ActionType
ActionTypeValues returns all values of the enum
func (ActionType) IsAActionType ¶
func (i ActionType) IsAActionType() bool
IsAActionType returns "true" if the value is listed in the enum definition. "false" otherwise
func (ActionType) MarshalJSON ¶
func (i ActionType) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaler interface for ActionType
func (ActionType) String ¶
func (i ActionType) String() string
func (*ActionType) UnmarshalJSON ¶
func (i *ActionType) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaler interface for ActionType
type AutoDeployAction ¶
type AutoDeployAction struct { ShouldRedeploy bool `json:"ShouldRedeployWhenMachineHasBeenDeployedTo"` // contains filtered or unexported fields }
func NewAutoDeployAction ¶
func NewAutoDeployAction(shouldRedeploy bool) *AutoDeployAction
func (*AutoDeployAction) GetActionType ¶
func (a *AutoDeployAction) GetActionType() ActionType
func (*AutoDeployAction) SetActionType ¶
func (a *AutoDeployAction) SetActionType(actionType ActionType)
type CommunityActionTemplate ¶
type CommunityActionTemplate struct { ActionType string `json:"ActionType" validate:"required,notblank"` Author string `json:"Author,omitempty"` Category string `json:"Category,omitempty"` Description string `json:"Description,omitempty"` ExternalId *uuid.UUID `json:"ExternalId,omitempty"` HistoryURL string `json:"HistoryUrl,omitempty"` Name string `json:"Name" validate:"required"` Packages []packages.PackageReference `json:"Packages,omitempty"` Parameters []actiontemplates.ActionTemplateParameter `json:"Parameters"` Properties map[string]core.PropertyValue `json:"Properties,omitempty"` Type string `json:"Type,omitempty"` Version int32 `json:"Version,omitempty"` Website string `json:"Website,omitempty"` resources.Resource }
CommunityActionTemplate represents a community action template in Octopus Deploy.
func NewCommunityActionTemplate ¶
func NewCommunityActionTemplate(name string, actionType string) *CommunityActionTemplate
NewCommunityActionTemplate initializes a community action template.
func (*CommunityActionTemplate) Validate ¶
func (c *CommunityActionTemplate) Validate() error
Validate checks the state of this CommunityActionTemplate and returns an error if invalid.
type CommunityActionTemplateService ¶
CommunityActionTemplateService handles communication with Account-related methods of the Octopus API.
func NewCommunityActionTemplateService ¶
func NewCommunityActionTemplateService(sling *sling.Sling, uriTemplate string) *CommunityActionTemplateService
NewCommunityActionTemplateService returns an CommunityActionTemplateService with a preconfigured client.
func (*CommunityActionTemplateService) Get ¶
func (s *CommunityActionTemplateService) Get(communityActionTemplatesQuery CommunityActionTemplatesQuery) (*resources.Resources[*CommunityActionTemplate], error)
Get returns a collection of community action templates based on the criteria defined by its input query parameter. If an error occurs, an empty collection is returned along with the associated error.
func (*CommunityActionTemplateService) GetAll ¶
func (s *CommunityActionTemplateService) GetAll() ([]*CommunityActionTemplate, error)
GetAll returns all community action templates. If none can be found or an error occurs, it returns an empty collection.
func (*CommunityActionTemplateService) GetByID ¶
func (s *CommunityActionTemplateService) GetByID(id string) (*CommunityActionTemplate, error)
GetByID returns the community action template that matches the input ID. If one cannot be found, it returns nil and an error.
func (*CommunityActionTemplateService) GetByIDs ¶
func (s *CommunityActionTemplateService) GetByIDs(ids []string) ([]*CommunityActionTemplate, error)
GetByIDs returns the accounts that match the input IDs.
func (*CommunityActionTemplateService) GetByName ¶
func (s *CommunityActionTemplateService) GetByName(name string) (*CommunityActionTemplate, error)
GetByName performs a lookup and returns the community action template with a matching name.
func (*CommunityActionTemplateService) Install ¶
func (s *CommunityActionTemplateService) Install(resource CommunityActionTemplate) (*CommunityActionTemplate, error)
Install installs a community step template.
func (*CommunityActionTemplateService) Update ¶
func (s *CommunityActionTemplateService) Update(resource CommunityActionTemplate) (*CommunityActionTemplate, error)
Update modifies a community action template based on the one provided as input.
type CreateReleaseAction ¶ added in v2.39.0
type CreateReleaseAction struct { ChannelID string `json:"ChannelId,omitempty"` // contains filtered or unexported fields }
func NewCreateReleaseAction ¶ added in v2.39.0
func NewCreateReleaseAction(channelId string) *CreateReleaseAction
func (*CreateReleaseAction) GetActionType ¶ added in v2.39.0
func (a *CreateReleaseAction) GetActionType() ActionType
func (*CreateReleaseAction) SetActionType ¶ added in v2.39.0
func (a *CreateReleaseAction) SetActionType(actionType ActionType)
type DeployLatestReleaseAction ¶
type DeployLatestReleaseAction struct { DestinationEnvironment string `json:"DestinationEnvironmentId"` ShouldRedeploy bool `json:"ShouldRedeployWhenReleaseIsCurrent"` SourceEnvironments []string `json:"SourceEnvironmentIds"` Variables string `json:"Variables"` // contains filtered or unexported fields }
func NewDeployLatestReleaseAction ¶
func NewDeployLatestReleaseAction(destinationEnvironment string, shouldRedeploy bool, sourceEnvironments []string, variables string) *DeployLatestReleaseAction
func (*DeployLatestReleaseAction) GetActionType ¶
func (a *DeployLatestReleaseAction) GetActionType() ActionType
func (*DeployLatestReleaseAction) SetActionType ¶
func (a *DeployLatestReleaseAction) SetActionType(actionType ActionType)
type DeployNewReleaseAction ¶
type DeployNewReleaseAction struct { Environment string `json:"EnvironmentId,omitempty"` Variables string `json:"Variable,omitempty"` VersionControlReference *VersionControlReference `json:"VersionControlReference,omitempty"` // contains filtered or unexported fields }
func NewDeployNewReleaseAction ¶
func NewDeployNewReleaseAction(environment string, variables string, versionControlReference *VersionControlReference) *DeployNewReleaseAction
func (*DeployNewReleaseAction) GetActionType ¶
func (a *DeployNewReleaseAction) GetActionType() ActionType
func (*DeployNewReleaseAction) SetActionType ¶
func (a *DeployNewReleaseAction) SetActionType(actionType ActionType)
type ITriggerAction ¶
type ITriggerAction interface { GetActionType() ActionType SetActionType(actionType ActionType) }
ITriggerAction defines the interface for trigger actions.
func FromJson ¶
func FromJson(rawMessage *json.RawMessage) (ITriggerAction, error)
type ProjectTriggerAction ¶
type ProjectTriggerAction struct { ActionType string `json:"ActionType"` DestinationEnvironmentID string `json:"DestinationEnvironmentId"` ShouldRedeployWhenMachineHasBeenDeployedTo bool `json:"ShouldRedeployWhenMachineHasBeenDeployedTo"` SourceEnvironmentID string `json:"SourceEnvironmentId"` }
func (*ProjectTriggerAction) GetActionType ¶
func (a *ProjectTriggerAction) GetActionType() ActionType
func (*ProjectTriggerAction) SetActionType ¶
func (a *ProjectTriggerAction) SetActionType(actionType ActionType)
type RunRunbookAction ¶
type RunRunbookAction struct { Environments []string `json:"EnvironmentIds"` Runbook string `json:"RunbookId"` Tenants []string `json:"TenantIds"` TenantTags []string `json:"TenantTags"` // contains filtered or unexported fields }
func NewRunRunbookAction ¶
func NewRunRunbookAction() *RunRunbookAction
func (*RunRunbookAction) GetActionType ¶
func (a *RunRunbookAction) GetActionType() ActionType
func (*RunRunbookAction) SetActionType ¶
func (a *RunRunbookAction) SetActionType(actionType ActionType)
type VersionControlReference ¶
Source Files ¶
- action_type.go
- action_type_string.go
- auto_deploy_action.go
- community_action_template.go
- community_action_template_service.go
- community_action_templates_query.go
- create_release_action.go
- deploy_latest_release_action.go
- deploy_new_release_action.go
- is_nil.go
- json.go
- project_trigger_action.go
- run_runbook_action.go
- scoped_deployment_action.go
- trigger_action.go
- version_control_reference.go