mirror of https://github.com/kubernetes/kops.git
Merge pull request #16009 from voriol/master
If specified, posts event data to URL upon instance interruption action.
This commit is contained in:
commit
5a3b1e2703
|
@ -280,6 +280,7 @@ spec:
|
|||
enableSQSTerminationDraining: true
|
||||
managedASGTag: "aws-node-termination-handler/managed"
|
||||
prometheusEnable: true
|
||||
webhookURL: "https://hooks.slack.com/services/YOUR/SLACK/URL"
|
||||
```
|
||||
|
||||
##### Queue Processor Mode
|
||||
|
|
|
@ -32,6 +32,8 @@ have a security group attached. These security groups are used for security grou
|
|||
allowing incoming traffic to the NLBs as well as traffic between the NLBs and their target
|
||||
instances.
|
||||
|
||||
* Posts event data to URL upon instance interruption action in aws-node-termination-handler with `WEBHOOK_URL`.
|
||||
|
||||
## GCP
|
||||
|
||||
* As of Kubernetes version 1.29, credentials for private GCR/AR repositories will be handled by the out-of-tree credential provider. This is an additional binary that each instance downloads from the assets repository.
|
||||
|
|
|
@ -5857,6 +5857,10 @@ spec:
|
|||
version:
|
||||
description: Version is the container image tag used.
|
||||
type: string
|
||||
webhookURL:
|
||||
description: If specified, posts event data to URL upon instance
|
||||
interruption action.
|
||||
type: string
|
||||
type: object
|
||||
nonMasqueradeCIDR:
|
||||
description: MasterIPRange string `json:",omitempty"`
|
||||
|
|
|
@ -998,6 +998,9 @@ type NodeTerminationHandlerSpec struct {
|
|||
CPURequest *resource.Quantity `json:"cpuRequest,omitempty"`
|
||||
// Version is the container image tag used.
|
||||
Version *string `json:"version,omitempty"`
|
||||
|
||||
// If specified, posts event data to URL upon instance interruption action.
|
||||
WebhookURL *string `json:"webhookURL,omitempty"`
|
||||
}
|
||||
|
||||
func (n *NodeTerminationHandlerSpec) IsQueueMode() bool {
|
||||
|
|
|
@ -1065,6 +1065,9 @@ type NodeTerminationHandlerSpec struct {
|
|||
CPURequest *resource.Quantity `json:"cpuRequest,omitempty"`
|
||||
// Version is the container image tag used.
|
||||
Version *string `json:"version,omitempty"`
|
||||
|
||||
// If specified, posts event data to URL upon instance interruption action.
|
||||
WebhookURL *string `json:"webhookURL,omitempty"`
|
||||
}
|
||||
|
||||
// NodeProblemDetector determines the node problem detector configuration.
|
||||
|
|
|
@ -6527,6 +6527,7 @@ func autoConvert_v1alpha2_NodeTerminationHandlerSpec_To_kops_NodeTerminationHand
|
|||
out.MemoryRequest = in.MemoryRequest
|
||||
out.CPURequest = in.CPURequest
|
||||
out.Version = in.Version
|
||||
out.WebhookURL = in.WebhookURL
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -6548,6 +6549,7 @@ func autoConvert_kops_NodeTerminationHandlerSpec_To_v1alpha2_NodeTerminationHand
|
|||
out.MemoryRequest = in.MemoryRequest
|
||||
out.CPURequest = in.CPURequest
|
||||
out.Version = in.Version
|
||||
out.WebhookURL = in.WebhookURL
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
@ -4926,6 +4926,11 @@ func (in *NodeTerminationHandlerSpec) DeepCopyInto(out *NodeTerminationHandlerSp
|
|||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
if in.WebhookURL != nil {
|
||||
in, out := &in.WebhookURL, &out.WebhookURL
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
@ -994,6 +994,9 @@ type NodeTerminationHandlerSpec struct {
|
|||
CPURequest *resource.Quantity `json:"cpuRequest,omitempty"`
|
||||
// Version is the container image tag used.
|
||||
Version *string `json:"version,omitempty"`
|
||||
|
||||
// If specified, posts event data to URL upon instance interruption action.
|
||||
WebhookURL *string `json:"webhookURL,omitempty"`
|
||||
}
|
||||
|
||||
// NodeProblemDetector determines the node problem detector configuration.
|
||||
|
|
|
@ -6782,6 +6782,7 @@ func autoConvert_v1alpha3_NodeTerminationHandlerSpec_To_kops_NodeTerminationHand
|
|||
out.MemoryRequest = in.MemoryRequest
|
||||
out.CPURequest = in.CPURequest
|
||||
out.Version = in.Version
|
||||
out.WebhookURL = in.WebhookURL
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -6803,6 +6804,7 @@ func autoConvert_kops_NodeTerminationHandlerSpec_To_v1alpha3_NodeTerminationHand
|
|||
out.MemoryRequest = in.MemoryRequest
|
||||
out.CPURequest = in.CPURequest
|
||||
out.Version = in.Version
|
||||
out.WebhookURL = in.WebhookURL
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
@ -4820,6 +4820,11 @@ func (in *NodeTerminationHandlerSpec) DeepCopyInto(out *NodeTerminationHandlerSp
|
|||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
if in.WebhookURL != nil {
|
||||
in, out := &in.WebhookURL, &out.WebhookURL
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
@ -5019,6 +5019,11 @@ func (in *NodeTerminationHandlerSpec) DeepCopyInto(out *NodeTerminationHandlerSp
|
|||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
if in.WebhookURL != nil {
|
||||
in, out := &in.WebhookURL, &out.WebhookURL
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
@ -212,6 +212,10 @@ spec:
|
|||
value: "{{ DefaultQueueName }}"
|
||||
- name: WORKERS
|
||||
value: "10"
|
||||
{{ if .WebhookURL }}
|
||||
- name: WEBHOOK_URL
|
||||
value: {{ .WebhookURL }}
|
||||
{{ end }}
|
||||
ports:
|
||||
- name: liveness-probe
|
||||
protocol: TCP
|
||||
|
|
Loading…
Reference in New Issue