k3s/cmd/kubeadm
Kubernetes Submit Queue 2e61da137b
Merge pull request #63799 from luxas/kubeadm_restructure_internal_config_usage
Automatic merge from submit-queue (batch tested with PRs 63314, 63884, 63799, 63521, 62242). 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: Restructure internal config usage and fix bugs

**What this PR does / why we need it**:
 - Moves the generic LoadYAML function from the versioned, external API package to a helper library so it can be consumed more easily
 - Makes the upgrading code use the internal version of the API (which always should be used anyway)
 - Moves all config-loading code to `configutil`, together with the migration code needed. This way we have everything in one centralized place, instead of duplicating that logic N times.
 - Makes `kubeadm init` use `configutil` for the reasons mentioned above.

This PR is needed in order to support multiple external API groups (like v1alpha2)

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Part of https://github.com/kubernetes/community/pull/2131

**Special notes for your reviewer**:
This PR depends on:
 - https://github.com/kubernetes/kubernetes/pull/63782
 - https://github.com/kubernetes/kubernetes/pull/63783

**Please review only the last (third) commit**

**Release note**:

```release-note
NONE
```
@kubernetes/sig-cluster-lifecycle-pr-reviews @liztio
2018-05-15 19:55:12 -07:00
..
app Merge pull request #63799 from luxas/kubeadm_restructure_internal_config_usage 2018-05-15 19:55:12 -07:00
test Autogenerated: hack/update-bazel.sh 2018-02-16 13:43:01 -08:00
.import-restrictions Control exactly what we use in kubeadm 2018-05-12 21:55:56 -04:00
BUILD Autogenerated: hack/update-bazel.sh 2018-02-16 13:43:01 -08:00
OWNERS Revisit the OWNERS file for kubeadm 2018-05-11 20:12:11 +03:00
kubeadm.go Add fmt.printf for other need 2017-08-18 16:07:56 +08:00