1. 23 May, 2018 10 commits
    • Kubernetes Submit Queue's avatar
      Merge pull request #64161 from lpabon/csi-remote-flaky · 86bd9771
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 64034, 64072, 64146, 64059, 64161). 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>.
      
      e2e: Remove flaky from CSI E2E test
      
      **What this PR does / why we need it**:
      The tests have been passing consistently and now we can remove the Flaky tag.
      
      See results here: https://k8s-testgrid.appspot.com/sig-storage#gce-flaky&width=5
      
      **Release note**:
      
      ```release-note
      NONE
      ```
      86bd9771
    • Kubernetes Submit Queue's avatar
      Merge pull request #64059 from wgliang/master.rename-controller-unit-test · 0ba60a3e
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 64034, 64072, 64146, 64059, 64161). 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>.
      
      Fixing wrong unit test naming of (pkg/controller/podautoscaler)
      
      **What this PR does / why we need it**:
      /kind cleanup
      
      Fixing wrong unit test naming of (pkg/controller/podautoscaler). Unit tests will not be executed, function name of _test.go file must start with Test*.
      
      **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
      Fixes #
      
      **Special notes for your reviewer**:
      
      **Release note**:
      
      ```release-note
      NONE
      ```
      0ba60a3e
    • Kubernetes Submit Queue's avatar
      Merge pull request #64146 from Lion-Wei/ipvs-lb · 094e605c
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 64034, 64072, 64146, 64059, 64161). 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 session affinity for LoadBalancer service with ESIPP
      
      **What this PR does / why we need it**:
      fix session affinity for LoadBalancer service with ESIPP
      
      **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
      Fixes #63351
      
      **Special notes for your reviewer**:
      In cases that loadbalancer type service with externaltrafficpolicy=local and session-affinity specified, traffic to loadbalancer should only route to backends that in the same node with kube-proxy. 
      
      **Release note**:
      ```release-note
      NONE
      ```
      094e605c
    • Kubernetes Submit Queue's avatar
      Merge pull request #64072 from CaoShuFeng/show_kind · 5fee0507
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 64034, 64072, 64146, 64059, 64161). 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 kubectl get --show-kind
      
      This pull request fix `kubectl get --show-kind`
      Before this change:
      ```json
      $ kubectl get pods --show-kind
      NAME                    READY     STATUS      RESTARTS   AGE
      pi-with-timeout-52sjs   0/1       Completed   0          1d
      pi-with-timeout-f5pb5   0/1       Completed   0          1d
      ```
      After this change:
      ```
      $ kubectl get pods --show-kind
      NAME                        READY     STATUS      RESTARTS   AGE
      pod/pi-with-timeout-52sjs   0/1       Completed   0          1d
      pod/pi-with-timeout-f5pb5   0/1       Completed   0          1d
      ```
      
      
      **What this PR does / why we need it**:
      
      **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
      Fixes #
      
      **Special notes for your reviewer**:
      /assign @soltysh 
      **Release note**:
      
      ```release-note
      NONE
      ```
      5fee0507
    • Kubernetes Submit Queue's avatar
      Merge pull request #64034 from deads2k/cli-62-wait · f9c88981
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 64034, 64072, 64146, 64059, 64161). 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 kubectl wait
      
      Adds a `kubectl wait --for=[delete|condition=condition-name] resource/string` command.  This allows generic waiting on well behaved conditions and for a resource or set of resources to be deleted.
      
      This was requested for delete to do foreground deletion
      
      WIP because I need to add test cases.
      
      
      @kubernetes/sig-cli-maintainers this is using a separation of concerns made possible by the genericclioptions to make an easily unit testable command.
      @smarterclayton 
      
      ```release-note
      adds a kubectl wait command
      ```
      f9c88981
    • Kubernetes Submit Queue's avatar
      Merge pull request #62933 from bsalamat/fix_pdb · b5cd7d81
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 63914, 63887, 64116, 64026, 62933). 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 preemption tests that use PDB
      
      **What this PR does / why we need it**:
      Scheduler integration tests that test preemption in presence of PDB had an issue causing PDB status not getting updated. This PR fixes the issue.
      
      **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
      Fixes #
      
      **Special notes for your reviewer**:
      
      **Release note**:
      
      ```release-note
      NONE
      ```
      
      /sig scheduling
      
      xref/ #57057
      b5cd7d81
    • Kubernetes Submit Queue's avatar
      Merge pull request #64026 from jsafrane/csi-selinux · 36b1f676
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 63914, 63887, 64116, 64026, 62933). 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>.
      
      Enable SELinux relabeling in CSI volumes
      
      **What this PR does / why we need it**:
      CSI volume plugin should provide correct information in `GetAttributes` call so kubelet can ask container runtime to relabel the volume. Therefore CSI volume plugin needs to check if a random volume mounted by a CSI driver supports SELinux or not by checking for "seclabel" mount or superblock option.
      
      
      **Which issue(s) this PR fixes**
      Fixes #63965
      
      **Release note**:
      ```release-note
      NONE
      ```
      
      @saad-ali @vladimirvivien @davidz627 
      @cofyc, FYI, I'm changing `struct mountInfo`.
      36b1f676
    • Kubernetes Submit Queue's avatar
      Merge pull request #64116 from deads2k/cli-64-portsforobj · c5bd053a
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 63914, 63887, 64116, 64026, 62933). 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 portsforobject from factory
      
      Removes another non-factory method out.
      
      /assign @juanvallejo
      
      ```release-note
      NONE
      ```
      c5bd053a
    • Kubernetes Submit Queue's avatar
      Merge pull request #63887 from luxas/kubeadm_kubelet_integration · 773ced14
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 63914, 63887, 64116, 64026, 62933). 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>.
      
      kubeadm: Write kubelet config file to disk and persist in-cluster
      
      **What this PR does / why we need it**:
      In order to make configuration flow from the cluster level to node level, we need a way for kubeadm to tell the kubelet what config to use. As of v1.10 (I think) the kubelet can read `--config` using the kubelet Beta ComponentConfiguration API, so now we have an interface to talk to the kubelet properly.
      
      This PR:
       - Writes the kubelet ComponentConfig to `/var/lib/kubelet/config.yaml` on init and join
       - Writes an environment file to source in the kubelet systemd dropin `/var/lib/kubelet/kubeadm-flags.env`. This file contain runtime flags that should be passed to the kubelet.
       - Uploads a ConfigMap with the name `kubelet-config-1.X`
       - Patches the node object so that it starts using the ConfigMap with updates using Dynamic Kubelet Configuration, **only if the feature gate is set** (currently alpha and off by default, not intended to be switched on in v1.11)
       - Updates the phase commands to reflect this new flow
      
      The kubelet dropin file I used now looks like this:
      ```
      # v1.11.x dropin as-is at HEAD
      # /etc/systemd/system/kubelet.service.d/10-kubeadm.conf
      ---
      [Service]
      Environment="KUBELET_KUBECONFIG_ARGS=--bootstrap-kubeconfig=/etc/kubernetes/bootstrap-kubelet.conf --kubeconfig=/etc/kubernetes/kubelet.conf"
      Environment="KUBELET_CONFIG_ARGS=--config=/var/lib/kubelet/config.yaml"
      EnvironmentFile-=/var/lib/kubelet/kubeadm-flags.env
      # Should default to 0 in v1.11: https://github.com/kubernetes/kubernetes/pull/63881, and hence not be here in the real v1.11 manifest
      Environment="KUBELET_CADVISOR_ARGS=--cadvisor-port=0"
      # Should be configurable via the config file: https://github.com/kubernetes/kubernetes/issues/63878, and hence be configured using the file in v1.11
      Environment="KUBELET_CERTIFICATE_ARGS=--rotate-certificates=true"
      ExecStart=
      ExecStart=/usr/bin/kubelet $KUBELET_KUBECONFIG_ARGS $KUBELET_CONFIG_ARGS $KUBELET_KUBEADM_ARGS $KUBELET_CADVISOR_ARGS $KUBELET_CERTIFICATE_ARGS $KUBELET_EXTRA_ARGS
      ---
      # v1.11.x dropin end goal
      # /etc/systemd/system/kubelet.service.d/10-kubeadm.conf
      ---
      [Service]
      Environment="KUBELET_KUBECONFIG_ARGS=--bootstrap-kubeconfig=/etc/kubernetes/bootstrap-kubelet.conf --kubeconfig=/etc/kubernetes/kubelet.conf"
      Environment="KUBELET_CONFIG_ARGS=--config=/var/lib/kubelet/config.yaml"
      EnvironmentFile-=/var/lib/kubelet/kubeadm-flags.env
      ExecStart=
      ExecStart=/usr/bin/kubelet $KUBELET_KUBECONFIG_ARGS $KUBELET_CONFIG_ARGS $KUBELET_KUBEADM_ARGS $KUBELET_EXTRA_ARGS
      ---
      # Environment file dynamically created at runtime by "kubeadm init"
      # /var/lib/kubelet/kubeadm-flags.env
      KUBELET_KUBEADM_ARGS=--cni-bin-dir=/opt/cni/bin --cni-conf-dir=/etc/cni/net.d --network-plugin=cni
      ```
      
      **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
      Fixes https://github.com/kubernetes/kubeadm/issues/822
      Fixes https://github.com/kubernetes/kubeadm/issues/571
      
      **Special notes for your reviewer**:
      
      **Release note**:
      
      ```release-note
      "kubeadm init" now writes a structured and versioned kubelet ComponentConfiguration file to `/var/lib/kubelet/config.yaml` and an environment file with runtime flags (you can source this file in the systemd kubelet dropin) to `/var/lib/kubelet/kubeadm-flags.env`.
      ```
      @kubernetes/sig-cluster-lifecycle-pr-reviews @mtaufen
      773ced14
    • Kubernetes Submit Queue's avatar
      Merge pull request #63914 from superbrothers/completion-init-containers · cecbbad1
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 63914, 63887, 64116, 64026, 62933). 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 initContainers into completion suggestions for kubectl logs/attach
      
      **What this PR does / why we need it**: This PR improves autocomplete of kubectl logs/attach to add initContainers into completion suggestions in addition to containers.
      
      ```
      $ cat <<EOL | kubectl apply -f -
      apiVersion: v1
      kind: Pod
      metadata:
        name: myapp-pod
      spec:
        initContainers:
        - name: init-myservice
          image: busybox
          command: ['sh', '-c', 'until nslookup myservice; do echo waiting for myservice; sleep 2; done;']
        - name: init-mydb
          image: busybox
          command: ['sh', '-c', 'until nslookup mydb; do echo waiting for mydb; sleep 2; done;']
        containers:
        - name: myapp-container
          image: busybox
          command: ['sh', '-c', 'echo The app is running! && sleep 3600']
      EOL
      $ kubectl logs myapp-pod <tab><tab>
      init-mydb        init-myservice   myapp-container
      ```
      
      **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
      Fixes #
      
      **Special notes for your reviewer**:
      
      **Release note**:
      
      ```release-note
      NONE
      ```
      cecbbad1
  2. 22 May, 2018 30 commits