If --taint is specified, set the taint value to empty (#322)
Add the old tolerations the examples to make it backward compatible during the switch
This commit is contained in:
@@ -27,3 +27,5 @@ spec:
|
||||
tolerations:
|
||||
- key: virtual-kubelet.io/provider
|
||||
operator: Exists
|
||||
- key: azure.com/aci
|
||||
effect: NoSchedule
|
||||
|
||||
@@ -29,3 +29,5 @@ spec:
|
||||
tolerations:
|
||||
- key: virtual-kubelet.io/provider
|
||||
operator: Exists
|
||||
- key: azure.com/aci
|
||||
effect: NoSchedule
|
||||
|
||||
@@ -18,3 +18,5 @@ spec:
|
||||
tolerations:
|
||||
- key: virtual-kubelet.io/provider
|
||||
operator: Exists
|
||||
- key: azure.com/aci
|
||||
effect: NoSchedule
|
||||
|
||||
@@ -21,3 +21,5 @@ spec:
|
||||
tolerations:
|
||||
- key: virtual-kubelet.io/provider
|
||||
operator: Exists
|
||||
- key: azure.com/aci
|
||||
effect: NoSchedule
|
||||
|
||||
@@ -25,3 +25,5 @@ spec:
|
||||
tolerations:
|
||||
- key: virtual-kubelet.io/provider
|
||||
operator: Exists
|
||||
- key: azure.com/aci
|
||||
effect: NoSchedule
|
||||
|
||||
@@ -81,13 +81,16 @@ func New(nodeName, operatingSystem, namespace, kubeConfig, provider, providerCon
|
||||
internalIP := os.Getenv("VKUBELET_POD_IP")
|
||||
|
||||
var defaultTaintKey string
|
||||
var defaultTaintValue string
|
||||
if taintKey != "" {
|
||||
defaultTaintKey = taintKey
|
||||
defaultTaintValue = ""
|
||||
} else {
|
||||
defaultTaintKey = "virtual-kubelet.io/provider"
|
||||
defaultTaintValue = provider
|
||||
}
|
||||
vkTaintKey := getEnv("VKUBELET_TAINT_KEY", defaultTaintKey)
|
||||
vkTaintValue := getEnv("VKUBELET_TAINT_VALUE", provider)
|
||||
vkTaintValue := getEnv("VKUBELET_TAINT_VALUE", defaultTaintValue)
|
||||
vkTaintEffectEnv := getEnv("VKUBELET_TAINT_EFFECT", "NoSchedule")
|
||||
var vkTaintEffect corev1.TaintEffect
|
||||
switch vkTaintEffectEnv {
|
||||
|
||||
Reference in New Issue
Block a user