1. 20 Nov, 2017 1 commit
  2. 17 Nov, 2017 14 commits
    • Kubernetes Submit Queue's avatar
      Merge pull request #54053 from WanLinghao/cmd_test_unused_function · 56e62b68
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      remove unused function in cmd_test.go
      
      PR removed unused defaultClientConfigForVersion() functions from cmd_test.go.
      
      
      
      **What this PR does / why we need it**:
      
      **Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #
      
      **Special notes for your reviewer**:
      
      **Release note**:
      
      ```
      NONE
      ```
      56e62b68
    • Kubernetes Submit Queue's avatar
      Merge pull request #55455 from mahdix/kind_visitor_fix · 52492e68
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Add support for CronJob to kind_visitor
      
      Fixes https://github.com/kubernetes/kubectl/issues/126
      52492e68
    • Kubernetes Submit Queue's avatar
      Merge pull request #54411 from frodenas/kubectl-pdb-fix · ad750b60
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Fixes kubectl Pod Disruption Budget and adds tests
      
      **What this PR does / why we need it**:
      
      This PR fixes several kubectl Pod Disruption Budget issues:
      * The `min-available` parameter in Pod Disruption Budget V1 is not required (otherwise it will never use the default value)
      * Removes the deprecated `min-available` default in Pod Disruption Budget V2
      * The `selector` parameter in Pod Disruption Budget V2 is required
      * Fixes (typo) the `max-unavailable` parameter check in Pod Disruption Budget V2
      * Fixes some  assertion error messages where the value printed was always the zero value of the parameter type instead of the parameter provided
      * Updated kubectl Pod Disruption Budget to use policy V1Beta1 instead of unversioned API (see https://github.com/kubernetes/kubectl/issues/90)
      * Add missing tests
      
      **Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes https://github.com/kubernetes/kubectl/issues/101
      
      **Special notes for your reviewer**:
      
      Spllited in several commits to make the review process easier. Please let me know if you prefer to squash some commits or if you prefer to split them in different PRs.
      
      **Release note**:
      
      ```release-note
      NONE
      ```
      
      /cc @kubernetes/sig-cli-pr-reviews
      ad750b60
    • Kubernetes Submit Queue's avatar
      Merge pull request #54823 from mtaufen/structure-eviction-thresholds · 00fe2cfe
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Lift embedded structure out of eviction-related KubeletConfiguration fields
      
      - Changes the following KubeletConfiguration fields from `string` to
      `map[string]string`:
        - `EvictionHard`
        - `EvictionSoft`
        - `EvictionSoftGracePeriod`
        - `EvictionMinimumReclaim`
      - Adds flag parsing shims to maintain Kubelet's public flags API, while
      enabling structured input in the file API.
      - Also removes `kubeletconfig.ConfigurationMap`, which was an ad-hoc flag
      parsing shim living in the kubeletconfig API group, and replaces it
      with the `MapStringString` shim introduced in this PR. Flag parsing
      shims belong in a common place, not in the kubeletconfig API.
      I manually audited these to ensure that this wouldn't cause errors
      parsing the command line for syntax that would have previously been
      error free (`kubeletconfig.ConfigurationMap` was unique in that it
      allowed keys to be provided on the CLI without values. I believe this was
      done in `flags.ConfigurationMap` to facilitate the `--node-labels` flag,
      which rightfully accepts value-free keys, and that this shim was then
      just copied to `kubeletconfig`). Fortunately, the affected fields
      (`ExperimentalQOSReserved`, `SystemReserved`, and `KubeReserved`) expect
      non-empty strings in the values of the map, and as a result passing the
      empty string is already an error. Thus requiring keys shouldn't break
      anyone's scripts.
      - Updates code and tests accordingly.
      
      Regarding eviction operators, directionality is already implicit in the
      signal type (for a given signal, the decision to evict will be made when
      crossing the threshold from either above or below, never both). There is
      no need to expose an operator, such as `<`, in the API. By changing
      `EvictionHard` and `EvictionSoft` to `map[string]string`, this PR
      simplifies the experience of working with these fields via the
      `KubeletConfiguration` type. Again, flags stay the same.
      
      Other things:
      - There is another flag parsing shim, `flags.ConfigurationMap`, from the
      shared flag utility. The `NodeLabels` field still uses
      `flags.ConfigurationMap`. This PR moves the allocation of the
      `map[string]string` for the `NodeLabels` field from
      `AddKubeletConfigFlags` to the defaulter for the external
      `KubeletConfiguration` type. Flags are layered on top of an internal
      object that has undergone conversion from a defaulted external object,
      which means that previously the mere registration of flags would have
      overwritten any previously-defined defaults for `NodeLabels` (fortunately
      there were none).
      
      Related: #53833 (lifting embedded structures out of string fields is part of getting this API to beta)
      
      ```release-note
      The EvictionHard, EvictionSoft, EvictionSoftGracePeriod, EvictionMinimumReclaim, SystemReserved, and KubeReserved fields in the KubeletConfiguration object (kubeletconfig/v1alpha1) are now of type map[string]string, which facilitates writing JSON and YAML files.
      ```
      00fe2cfe
    • Kubernetes Submit Queue's avatar
      Merge pull request #54507 from micahhausler/aws-elb-security-policy · b223955c
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 54134, 54507). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Added service annotation for AWS ELB SSL policy
      
      **What this PR does / why we need it**:
      
      This work adds a new supported service annotation for AWS clusters, `service.beta.kubernetes.io/aws-load-balancer-ssl-negotiation-policy`, which lets users specify which [predefined AWS SSL policy](http://docs.aws.amazon.com/elasticloadbalancing/latest/classic/elb-security-policy-table.html) they would like to use.
      
      **Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #
      
      Fixes #43744
      
      **Special notes for your reviewer**:
      
      While this PR doesn't allow users to define their own cipher policy in an annotation, a user could (out of band) create their own policy on an ELB with the naming convention `k8s-SSLNegotiationPolicy-<my-policy-name>` and specify it with the above annotation.
      
      This is my second k8s PR, and I don't have experience with an e2e test, would that be required for this change? I did run this in a kubeadm cluster and it worked like a charm. I was able to choose different predefined policies, and revert to the default policy when I removed the annotation.
      
      **Release note**:
      
      ```release-note
      Added service annotation for AWS ELB SSL policy
      ```
      b223955c
    • Kubernetes Submit Queue's avatar
      Merge pull request #54134 from chentao1596/plugin-pkg-scheduler-util-non-zero-unit-test · a00b766a
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Adding unit tests to methods of 'scheduler/algorithm/priorities/util'
      
      What this PR does / why we need it:
      
       1) Adding unit tests to methods of 'non_zero.go'
       2) Adding unit tests to methods of 'util.go'
       3) Adding/Modifing unit tests to methods of 'topologies.go'
      
      thank you!
      a00b766a
    • Kubernetes Submit Queue's avatar
      Merge pull request #55836 from smarterclayton/status_errors · d20b1569
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 55392, 55491, 51914, 55831, 55836). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Guarantee that status errors have a kind set
      d20b1569
    • Kubernetes Submit Queue's avatar
      Merge pull request #55831 from Random-Liu/rename-log-dump-env · ebd3d680
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 55392, 55491, 51914, 55831, 55836). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Rename log-dump env to `LOG_DUMP_SYSTEMD_SERVICES`.
      
      For https://github.com/kubernetes/features/issues/286.
      
      Rename `SYSTEMD_SERVICES` to `LOG_DUMP_SYSTEMD_SERVICES`. test-infra disables log dump in our e2e framework, and uses a different log dump logic https://github.com/kubernetes/test-infra/blob/master/kubetest/e2e.go#L480-L497. So the flags we added in https://github.com/kubernetes/kubernetes/pull/55288 will not work in test-infra.
      
      Fortrunately, test-infra is using the same script `cluster/log-dump/log-dump.sh`, so we could still configure systemd services by setting the environment variable globally.
      
      The original environment variable name is too general for setting globally, change it to a more specific name.
      
      **Release note**:
      
      ```release-note
      none
      ```
      ebd3d680
    • Kubernetes Submit Queue's avatar
      Merge pull request #51914 from sergeylanzman/master · 79c22745
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 55392, 55491, 51914, 55831, 55836). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Move regexp.MustCompile to global variable
      
      Move regexp.MustCompile to global variable.
      regexp.MustCompile heavy function and can be run on init app
      ```release-note
      NONE
      ```
      79c22745
    • Kubernetes Submit Queue's avatar
      Merge pull request #55491 from gnufied/fix-dangling-attach-errors · bb82a3ac
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 55392, 55491, 51914, 55831, 55836). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Fix dangling attach errors
      
      Detach volumes from shutdown nodes and ensure that
      dangling volumes are handled correctly in AWS
      
      Fixes https://github.com/kubernetes/kubernetes/issues/52573 
      
      ```release-note
      Implement correction mechanism for dangling volumes attached for deleted pods
      ```
      bb82a3ac
    • Kubernetes Submit Queue's avatar
      Merge pull request #55392 from sttts/sttts-remove-policy-v1alpha1 · 8413f36a
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 55392, 55491, 51914, 55831, 55836). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
      
      Remove unused pkg/apis/policy/v1alpha1
      8413f36a
    • Michael Taufen's avatar
      omitempty · 617b4985
      Michael Taufen authored
      617b4985
    • Michael Taufen's avatar
      Lift embedded structure out of eviction-related KubeletConfiguration fields · 1085b6f7
      Michael Taufen authored
      - Changes the following KubeletConfiguration fields from `string` to
      `map[string]string`:
        - `EvictionHard`
        - `EvictionSoft`
        - `EvictionSoftGracePeriod`
        - `EvictionMinimumReclaim`
      - Adds flag parsing shims to maintain Kubelet's public flags API, while
      enabling structured input in the file API.
      - Also removes `kubeletconfig.ConfigurationMap`, which was an ad-hoc flag
      parsing shim living in the kubeletconfig API group, and replaces it
      with the `MapStringString` shim introduced in this PR. Flag parsing
      shims belong in a common place, not in the kubeletconfig API.
      I manually audited these to ensure that this wouldn't cause errors
      parsing the command line for syntax that would have previously been
      error free (`kubeletconfig.ConfigurationMap` was unique in that it
      allowed keys to be provided on the CLI without values. I believe this was
      done in `flags.ConfigurationMap` to facilitate the `--node-labels` flag,
      which rightfully accepts value-free keys, and that this shim was then
      just copied to `kubeletconfig`). Fortunately, the affected fields
      (`ExperimentalQOSReserved`, `SystemReserved`, and `KubeReserved`) expect
      non-empty strings in the values of the map, and as a result passing the
      empty string is already an error. Thus requiring keys shouldn't break
      anyone's scripts.
      - Updates code and tests accordingly.
      
      Regarding eviction operators, directionality is already implicit in the
      signal type (for a given signal, the decision to evict will be made when
      crossing the threshold from either above or below, never both). There is
      no need to expose an operator, such as `<`, in the API. By changing
      `EvictionHard` and `EvictionSoft` to `map[string]string`, this PR
      simplifies the experience of working with these fields via the
      `KubeletConfiguration` type. Again, flags stay the same.
      
      Other things:
      - There is another flag parsing shim, `flags.ConfigurationMap`, from the
      shared flag utility. The `NodeLabels` field still uses
      `flags.ConfigurationMap`. This PR moves the allocation of the
      `map[string]string` for the `NodeLabels` field from
      `AddKubeletConfigFlags` to the defaulter for the external
      `KubeletConfiguration` type. Flags are layered on top of an internal
      object that has undergone conversion from a defaulted external object,
      which means that previously the mere registration of flags would have
      overwritten any previously-defined defaults for `NodeLabels` (fortunately
      there were none).
      1085b6f7
    • David Ashpole's avatar
  3. 16 Nov, 2017 25 commits