Skip to content
This repository has been archived by the owner on Jul 30, 2021. It is now read-only.

checkpointer: ignore Affinity within podspec (w/ tests) #1007

Commits on Oct 11, 2018

  1. checkpointer: ignore Affinity within podspec

    Kubernetes 1.12.x introduced new logic for Affinity [1]. In addition to
    new logic, the Pod contains a default affinity. The new default affinity
    gets serialized into the checkpoint file, and the 1.12.x kubelet does
    not restore the pod due to the affinity.
    
    This PR removes the affinity from the spec and documents that affinity's
    are not supported.
    
    ```
    "affinity": {
          "nodeAffinity": {
            "requiredDuringSchedulingIgnoredDuringExecution": {
              "nodeSelectorTerms": [
                {
                  "matchExpressions": null
                }
              ]
            }
          }
        },
    
    ```
    
    [1] kubernetes/kubernetes#68173
    [2] https://github.com/kubernetes/kubernetes/blob/e39b510726113581c6f6a9c2db1753d794aa9cce/pkg/controller/daemon/util/daemonset_util.go#L183-L196
    rphillips committed Oct 11, 2018
    Configuration menu
    Copy the full SHA
    966008d View commit details
    Browse the repository at this point in the history