1. 25 Feb, 2018 17 commits
    • Kubernetes Submit Queue's avatar
      Merge pull request #57415 from stealthybox/feature/kubeadm_594-etcd_tls · b32e9c45
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 59159, 60318, 60079, 59371, 57415). 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>.
      
      Feature/kubeadm 594 etcd TLS on init/upgrade
      
      **What this PR does / why we need it**:
      On `kubeadm init`/`kubeadm upgrade`, this PR generates certificates for securing local etcd:
      - etcd serving cert
      - etcd peer cert
      - apiserver etcd client cert
      
      Flags and hostMounts are added to the etcd and apiserver static-pods to load these certs.
      For connections to etcd, `https` is now used in favor of `http` and tests have been added/updated.
      
      Etcd only listens on localhost, so the serving cert SAN defaults to `DNS:localhost,IP:127.0.0.1`.
      The etcd peer cert has SANs for `<hostname>,<api-advertise-address>`, but is unused.
      
      New kubeadm config options, `Etcd.ServerCertSANs` and `Etcd.PeerCertSANs`, are used for user additions to the default certificate SANs for the etcd server and peer certs.
      
      This feature continues to utilize the existence of `MasterConfiguration.Etcd.Endpoints` as a feature gate for external-etcd.
      If the user passes flags to configure `Etcd.{CAFile,CertFile,KeyFile}` but they omit `Endpoints`, these flags will be unused, and a warning is printed.
      
      New phase commands:
      ```
      kubeadm alpha phase certs etcd-server
      kubeadm alpha phase certs etcd-peer
      kubeadm alpha phase certs apiserver-etcd-client 
      ```
      
      **Which issue(s) this PR fixes**
      Fixes https://github.com/kubernetes/kubeadm/issues/594
      
      **Special notes for your reviewer**:
      
      #### on the master
      these should fail:
      ```bash
      curl localhost:2379/v2/keys  # no output
      curl --cacert /etc/kubernetes/pki/ca.crt https://localhost:2379/v2/keys  # handshake error
      ```
      these should succeed:
      ```
      cd /etc/kubernetes/pki
      curl --cacert ca.crt --cert apiserver-etcd-client.crt --key apiserver-etcd-client.key https://localhost:2379/v2/keys
      ```
      
      **Release note**:
      ```release-note
      On cluster provision or upgrade, kubeadm now generates certs and secures all connections to the etcd static-pod with mTLS.
      ```
      b32e9c45
    • Kubernetes Submit Queue's avatar
      Merge pull request #59371 from andrewrynhard/fix-liveness-probes · a0dd88bf
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 59159, 60318, 60079, 59371, 57415). 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: use localhost for API server liveness probe
      
      **What this PR does / why we need it**:
      The current liveness probe does not work with an HA cluster created with kubeadm. The probe's `host` value will be set to the IP address of the machine where `kubeadm --init` is run. For other master nodes, the IP address will be wrong.
      
      **Special notes for your reviewer**:
      None
      **Release note**:
      ```release-note
      NONE
      ```
      
      /cc @timothysc
      a0dd88bf
    • Kubernetes Submit Queue's avatar
      Merge pull request #60079 from kawych/external_metrics_api · 2482e34b
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 59159, 60318, 60079, 59371, 57415). 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>.
      
      Introduce External Metrics API
      
      **What this PR does / why we need it**:
      Introduce External Metrics API
      
      This PR introduces External Metrics API which has been proposed: xref https://github.com/kubernetes/community/pull/1802
      
      **Release note**:
      ```release-note
      NONE
      ```
      2482e34b
    • Kubernetes Submit Queue's avatar
      Merge pull request #60318 from jiayingz/api-change · e31c8a22
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 59159, 60318, 60079, 59371, 57415). 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>.
      
      Made a couple API changes to deviceplugin/v1beta1 to avoid future
      
      incompatible API changes:
      - Add GetDevicePluginOptions rpc call. This is needed when we switch
        from Registration service to probe-based plugin watcher.
      - Change AllocateRequest and AllocateResponse to allow device requests
        from multiple containers in a pod. Currently only made mechanical
        change on the devicemanager and test code to cope with the API but
        still issues an Allocate call per container. We can modify the
        devicemanager in 1.11 to issue a single Allocate call per pod.
        The change will also facilitate incremental API change to communicate
        pod level information through Allocate rpc if there is such future
        need.
      
      
      
      **What this PR does / why we need it**:
      Made a couple API changes to deviceplugin/v1beta1 to avoid future incompatible API changes.
      
      **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/kubernetes/issues/59370
      
      **Special notes for your reviewer**:
      
      **Release note**:
      
      ```release-note
      
      ```
      e31c8a22
    • Kubernetes Submit Queue's avatar
      Merge pull request #59159 from roycaihw/dfifo · 0394ffba
      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 comments about potential race in delta fifo
      
      **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**:
      
      **Release note**:
      
      ```release-note
      NONE
      ```
      
      /sig api-machinery
      0394ffba
    • Kubernetes Submit Queue's avatar
      Merge pull request #59941 from agau4779/gce-external-lb-tests · f49f799d
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 60324, 60269, 59771, 60314, 59941). 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>.
      
      [GCE] Refactor ExternalLoadBalancer Tests
      
      **What this PR does / why we need it**:
      
      - Refactors the ExternalLoadBalancer tests to use the generated GCE mock instead of FakeCloudAddressService, FakeCloudForwardingRuleService.
      - Adds hooks to populate NetworkTier on Alpha resources
      - Moves shared code to top of the external loadbalancer test file
      - Moves NetworkTier into a constants file at the cloud level, so it is more easily called in subpackages
      
      **Special notes for your reviewer**:
      
      ```release-note
      NONE
      ```
      f49f799d
    • Kubernetes Submit Queue's avatar
      Merge pull request #60314 from mtaufen/kubelet-manifest-is-oldspeak · 720c29b3
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 60324, 60269, 59771, 60314, 59941). 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>.
      
      expunge the word 'manifest' from Kubelet's config API
      
      The word 'manifest' technically refers to a container-group specification
      that predated the Pod abstraction. We should avoid using this legacy
      terminology where possible. Fortunately, the Kubelet's config API will
      be beta in 1.10 for the first time, so we still had the chance to make
      this change.
      
      I left the flags alone, since they're deprecated anyway.
      
      I changed a few var names in files I touched too, but this PR is the
      just the first shot, not the whole campaign
      (`git grep -i manifest | wc -l -> 1248`).
      
      ```release-note
      Some field names in the Kubelet's now v1beta1 config API differ from the v1alpha1 API: PodManifestPath is renamed to PodPath, ManifestURL is renamed to PodURL, ManifestURLHeader is renamed to PodURLHeader.
      ```
      720c29b3
    • Kubernetes Submit Queue's avatar
      Merge pull request #59771 from MrHohn/custom-pod-dns-e2e · ac25308c
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 60324, 60269, 59771, 60314, 59941). 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>.
      
      Promote configurable pod resolv.conf to Beta and add an e2e test
      
      **What this PR does / why we need it**:
      Feature issue: https://github.com/kubernetes/features/issues/504
      
      There is no semantic changes. `CustomPodDNS` feature gate will be turned on by default.
      
      **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 #56521
      
      **Special notes for your reviewer**:
      /assign @bowei @thockin 
      
      **Release note**:
      
      ```release-note
      Adds BETA support for `DNSConfig` field in PodSpec and `DNSPolicy=None`.
      ```
      ac25308c
    • Kubernetes Submit Queue's avatar
      Merge pull request #60269 from smarterclayton/crd_printing · 0f9b5e9f
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 60324, 60269, 59771, 60314, 59941). 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>.
      
      Implement a stub server printer for CRDs
      
      This wires up TableConvertor to CRDs and puts a basic implementation in place for custom paths. However, since our OpenAPISchema can't store OpenAPI extension fields there is no way to expose the custom column piece that get.go supports today (`x-kubernetes-print-columns`). That piece can be implemented separately and needs discussion.
      
      As this is purely exposing the default interface, very low risk. Will add an e2e test that covers this under a registered CRD.
      
      @soltysh @sttts @kubernetes/sig-api-machinery-pr-reviews
      
      A couple of options for wiring up the actual definition:
      
      1. add a new "extensions" map to spec.validation
         1. Downside: won't handle future child nested fields, not the correct schema
      2. try to change the OpenAPISchema3 field to support extensions
         1. Would require a breaking protobuf change, is also very difficult
         2. Could store the entire schema as opaque JSON and then parse on load (might be the right thing anyway)
      3. Support this as an annotation in 1.11 - `alpha.customresource.k8s.io/x-kubernetes-print-columns` like the CLI
      
      Part of #58536
      0f9b5e9f
    • Kubernetes Submit Queue's avatar
      Merge pull request #60324 from mikedanese/id-test1 · 15e34b13
      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>.
      
      integration: refactor, cleanup, and add more tests for TokenRequest
      
      ref #58790
      
      ```release-note
      NONE
      ```
      15e34b13
    • Kubernetes Submit Queue's avatar
      Merge pull request #51249 from tengqm/service-ip-cidr · 9714b647
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 59882, 59434, 57722, 60320, 51249). 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>.
      
      Expose default service IP CIDR in apiserver
      
      **What this PR does / why we need it**:
      The `--service-cluster-ip-range` parameter of API server is very important for deploying Kubernetes on some clouds. The default CIDR "10.0.0.0/24" should be exposed at least from the API server's help message so that users have a better idea whether they need to change it.
      This patch exposes this default value in API server's help message.
      
      **Which issue this PR fixes** : fixes #51248
      
      **Release note**:
      ```
      NONE
      ```
      9714b647
    • Kubernetes Submit Queue's avatar
      Merge pull request #60320 from cjcullen/flags · 1f03d401
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 59882, 59434, 57722, 60320, 51249). 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>.
      
      Allow TTLs to be plumbed through to webhook authn/authz in gce scripts.
      
      Just allows these flags to be configured from the startup scripts.
      1f03d401
    • Kubernetes Submit Queue's avatar
      Merge pull request #57722 from CaoShuFeng/finalizer · a1a786ee
      Kubernetes Submit Queue authored
      Automatic merge from submit-queue (batch tested with PRs 59882, 59434, 57722, 60320, 51249). 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>.
      
      [garbage collector] fix log info
      
      typo
      
      
      **Release note**:
      
      ```release-note
      NONE
      ```
      a1a786ee
    • Kubernetes Submit Queue's avatar
      Merge pull request #59434 from liggitt/optional-subsets · 5a5af343
      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>.
      
      Indicate endpoint subsets are an optional field
      
      Fixes #59403 
      
      ```release-note
      NONE
      ```
      5a5af343
    • Kubernetes Submit Queue's avatar
      Merge pull request #59882 from… · fa710e7e
      Kubernetes Submit Queue authored
      Merge pull request #59882 from kris-nova/kubeadm-demote-controlplane-passthrough-flags-to-phases-alpha
      
      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>.
      
      kubeadm: Demote controlplane passthrough flags to phases alpha
      
      After a discussion in sig cluster lifecycle we agreed that the passthrough flags should live in phases alpha, and not be 1st class flags. They already exist in the alpha command, so just removing from here.
      
      
      
      **What this PR does / why we need it**:
      
      We introduced some flags as 1st class flags in #58080 and decided as a sig that the flags should only live in the `alpha` command. This PR removes the flags from the `init` command so they only exist in the `alpha` command
      
      **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 #
      
      relates to kubernetes/kubernetes/pull/58080
      fixes kubernetes/kubeadm/issues/676
      
      **Special notes for your reviewer**:
      
      This is a cosmetic change, and doesn't alter any functionality of the program, only the avenue in which a user access functionality in the program.
      
      **Release note**:
      
      ```release-note
      kubeadm: Demote controlplane passthrough flags to alpha flags
      ```
      fa710e7e
    • Kubernetes Submit Queue's avatar
      Merge pull request #60170 from jiayingz/dp-feature-beta · bd155ec3
      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>.
      
      DevicePlugins feature is beta in 1.10 release
      
      **What this PR does / why we need it**:
      Graduates DevicePlugins feature to beta.
      
      **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/kubernetes/issues/56649
      
      **Special notes for your reviewer**:
      
      **Release note**:
      
      ```release-note
      DevicePlugins feature graduates to beta.
      ```
      bd155ec3
    • Kubernetes Submit Queue's avatar
      Merge pull request #60306 from danwinship/proxier-connstate-new · c11ae9d2
      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>.
      
      Only run connection-rejecting rules on new connections
      
      Kube-proxy has two iptables chains full of rules to reject incoming connections to services that don't have any endpoints. Currently these rules get tested against all incoming packets, but that's unnecessary; if a connection to a given service has already been established, then we can't have been rejecting connections to that service. By only checking the first packet in each new connection, we can get rid of a lot of unnecessary checks on incoming traffic.
      
      Fixes #56842
      
      **Release note**:
      ```release-note
      Additional changes to iptables kube-proxy backend to improve performance on clusters with very large numbers of services.
      ```
      c11ae9d2
  2. 24 Feb, 2018 23 commits