Documentation ¶
Index ¶
- Constants
- type AutoScaling
- func (a *AutoScaling) GetInstanceStatusAndAutoScalingGroupName(instanceID *string) (*string, *string, error)
- func (a *AutoScaling) GetLifecycleHookName(autoScalingGroupName *string) (*string, error)
- func (a *AutoScaling) IsTerminating(status *string) bool
- func (a *AutoScaling) SendNotification(instanceID *string, autoScalingGroupName *string, lifecycleHookName *string) error
- type Options
Constants ¶
View Source
const ( // InstanceTerminatingStatus describes EC2 instance termination status InstanceTerminatingStatus = "Terminating:Wait" // LifecycleActionResultContinue describes ASG instance lifecycle continue result LifecycleActionResultContinue = "CONTINUE" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AutoScaling ¶
type AutoScaling struct { AutoScaling autoscalingiface.AutoScalingAPI Options *Options }
AutoScaling type is a AWS EC2 AutoScaling API facade
func New ¶
func New(session *session.Session, options *Options) *AutoScaling
New creates a new AutoScaling
func (*AutoScaling) GetInstanceStatusAndAutoScalingGroupName ¶
func (a *AutoScaling) GetInstanceStatusAndAutoScalingGroupName(instanceID *string) (*string, *string, error)
GetInstanceStatusAndAutoScalingGroupName get an AWS EC2 instance status and its ASG name by instanceID
func (*AutoScaling) GetLifecycleHookName ¶
func (a *AutoScaling) GetLifecycleHookName(autoScalingGroupName *string) (*string, error)
GetLifecycleHookName gets an AWS ASG lifecycle hook name by autoScalingGroupName
func (*AutoScaling) IsTerminating ¶
func (a *AutoScaling) IsTerminating(status *string) bool
IsTerminating returns true if the provided status is in terminating state
func (*AutoScaling) SendNotification ¶
func (a *AutoScaling) SendNotification(instanceID *string, autoScalingGroupName *string, lifecycleHookName *string) error
SendNotification sends a notification to AWS ASG using provided instanceID, autoScalingGroupName and lifecycleHookName
Click to show internal directories.
Click to hide internal directories.