Dan Winship
e2900da46a
Remove unnecessary utiliptables.Interface arg from local detectors
...
getLocalDetector() used to pass a utiliptables.Interface to
NewDetectLocalByCIDR() so that NewDetectLocalByCIDR() could verify
that the passed-in CIDR was of the same family as the iptables
interface. It would make more sense for getLocalDetector() to verify
this itself and just *not call NewDetectLocalByCIDR* if the families
don't match, and that's what the code does now. So there's no longer
any need to pass the utiliptables.Interface to the local detector.
2023-07-05 09:11:23 -04:00
Dan Winship
7690c6e812
Simplify getDualStackLocalDetectorTuple
...
Since the single-stack and dual-stack local-detector-getters now have
the same behavior in terms of error-checking and dual-stack config, we
can just replace the contents of getDualStackLocalDetectorTuple() with
a pair of calls to getLocalDetector().
2023-07-05 09:09:54 -04:00
Dan Winship
cefd50a753
Improve the single-stack LocalDetector behavior
...
1. When bringing up a single-stack kube-proxy in a dual-stack cluster,
allow using either the primary or secondary IP family.
2. Since the earlier config-checking code will already have bailed out
if the single-stack configuration is unusably broken, we don't need to
do that here. Instead, just return a no-op local detector if there are
no usable CIDRs of the expected IP family.
2023-07-05 09:06:25 -04:00
Dan Winship
bfccfa7016
Add names to the getLocalDetector unit tests, use t.Run
2023-07-05 09:06:25 -04:00
Kubernetes Prow Robot
4c18d40af1
Merge pull request #119075 from chendave/test_gv
...
kubeadm: check the GV after the config migration
2023-07-04 22:00:54 -07:00
Kubernetes Prow Robot
76227fdb3d
Merge pull request #118874 from my-git9/dns-ut
...
kubeadm: increase ut coverage kubeadm/app/phases/dns
2023-07-04 19:30:54 -07:00
Dave Chen
31943cc3f4
kubeadm: check the GV after the config migration
...
Signed-off-by: Dave Chen <dave.chen@arm.com>
2023-07-05 10:04:12 +08:00
Kubernetes Prow Robot
68b7685b2a
Merge pull request #119081 from sttts/sttts-public-ip-validation-move
...
kube-apiserver: move "public IP matches IP family" check to option validation
2023-07-04 14:28:54 -07:00
Dr. Stefan Schimanski
4149933ed2
kube-apiserver: move "public IP matches IP family" check to option validation
2023-07-04 22:28:27 +02:00
Kubernetes Prow Robot
8d0e46a5ec
Merge pull request #119041 from sttts/sttts-move-back-master-count
...
cmd/kube-apiserver: move back master count variable from generic controlplane
2023-07-04 13:22:54 -07:00
Kubernetes Prow Robot
0235a5a206
Merge pull request #118707 from pacoxu/unwanted-status-order
...
update the unwanted-dependencies order
2023-07-04 12:20:54 -07:00
xin.li
c26e1ba10c
[UT] increase coverage kubeadm/app/phases/dns
...
Signed-off-by: xin.li <xin.li@daocloud.io>
2023-07-04 22:11:32 +08:00
Kubernetes Prow Robot
3149875175
Merge pull request #119059 from pacoxu/migrate-experimental-v1beta4
...
kubeadm: fix "migrate config --allow-experimental-api" to print v1beta4 kubeadm configurations instead of v1beta3
2023-07-04 06:28:53 -07:00
Kubernetes Prow Robot
75889ecec5
Merge pull request #119003 from danwinship/proxy-single-dual
...
do a better job of validating IP family of kube-proxy config
2023-07-04 02:16:53 -07:00
Paco Xu
01b1174c11
kubeadm: fix "migrate config --allow-experimental-api" to print v1beta4 kubeadm configurations instead of v1beta3
2023-07-04 15:20:43 +08:00
Kubernetes Prow Robot
746b88c6ff
Merge pull request #118867 from chendave/env_custom
...
kubeadm: Support custom env in control plane component
2023-07-03 22:02:52 -07:00
Dave Chen
c68a6b0745
kubeadm: fix fuzzing for ExtraEnvs defined in the control plane component
...
Signed-off-by: Dave Chen <dave.chen@arm.com>
2023-07-04 10:01:26 +08:00
Dave Chen
80b035a116
kubeadm: Support custom env in control plane component
...
Signed-off-by: Dave Chen <dave.chen@arm.com>
2023-07-04 09:57:07 +08:00
Dan Winship
a966d18608
Double-check the proxy configuration vs the available IP families
2023-07-03 08:34:06 -04:00
Dr. Stefan Schimanski
36e458612a
cmd/kube-apiserver: move back master count variable from generic controlplane
2023-07-03 13:20:29 +02:00
Kubernetes Prow Robot
14b08b82e4
Merge pull request #118941 from neolit123/1.28-restore-test-function-for-config-migrate
...
kubeadm: restore and generalize the TestMigrateOldConfig test
2023-07-01 03:18:48 -07:00
Dan Winship
1f2bf32e95
Figure out single-stack/dual-stack support before creating the proxier
...
Rather than having this as part of createProxier(), explicitly figure
out what IP families the proxier can support beforehand, and bail out
if this conflicts with the detected IP family.
2023-06-30 17:43:04 -04:00
Dan Winship
8abfa89e82
Move proxy platformSetup call, and do LocalDetector setup from there
2023-06-30 17:39:36 -04:00
Dan Winship
ebb0fdd4f6
Don't explicitly filter config.NodePortAddresses by IP family
...
There's no need to do this any more: proxyutil.NodePortAddresses does
it itself.
2023-06-30 12:32:59 -04:00
Dan Winship
a74b9fde3a
Don't pass around full node in proxy constructor, just pass PodCIDRs
2023-06-30 11:30:17 -04:00
Lubomir I. Ivanov
0537c1da56
kubeadm: move migrate / validate tests out of config_tests.go
...
Place the tests in common_tests.go on the backend side in
common_tests.go. A test for migrate TestMigrateOldConfig
was already present there. Apply slightly better coverage to it
and rename desc -> name.
Fix typo in argument oldConfig -> config in ValidateConfig().
2023-06-30 18:14:10 +03:00
Kubernetes Prow Robot
7bac0cee89
Merge pull request #118946 from SataQiu/clean-kubeadm-20230629
...
kubeadm: remove unused Kind and Resource functions from output API
2023-06-29 02:51:47 -07:00
Kubernetes Prow Robot
4036b6fb41
Merge pull request #118922 from champtar/kubeadm-backdate-ca
...
kubeadm: backdate generated CAs
2023-06-28 12:28:56 -07:00
SataQiu
24f4785e3e
kubeadm: remove unused Kind and Resource functions from output API
2023-06-29 00:16:38 +08:00
SataQiu
90f82d05ce
kubeadm: remove unused Kind and Resource functions from kubeadm internal API
2023-06-28 23:36:53 +08:00
Lubomir I. Ivanov
fd15c6791a
kubeadm: restore and generalize the TestMigrateOldConfig test
...
The test required two APIs to be available to test for migration.
Keep it simple and use a variable "gv" on top of the function body
to easily swap the version to be tested once an old API is deleted.
e.g. currently v1beta3 is the "old" API, v1beta4 is the "new" one.
Ultimately, this test only makes sure that the expected kinds are
available post migration.
2023-06-28 18:21:57 +03:00
Kubernetes Prow Robot
52457842d1
Merge pull request #117055 from cyclinder/csi_migration
...
remove CSI-migration gate
2023-06-28 04:28:31 -07:00
Kubernetes Prow Robot
ddbf3575a7
Merge pull request #116729 from AxeZhan/handlers_sync
...
[Scheduler] Make sure handlers have synced before scheduling
2023-06-28 01:26:31 -07:00
Etienne Champetier
812556365b
kubeadm: backdate generated CAs by 5 minutes
...
This allow for a small time jump backward after
certificates generation.
Signed-off-by: Etienne Champetier <e.champetier@ateme.com>
2023-06-28 00:12:29 -04:00
Kubernetes Prow Robot
1c32c3bd9f
Merge pull request #118866 from neolit123/1.28-add-v1beta4-to-scheme
...
kubeadm: add v1beta4 to scheme; add --allow-experimental-api flag
2023-06-27 08:56:44 -07:00
kidddddddddddddddddddddd
9c7166ff63
wait for eventhandlers to sync before run scheduler
2023-06-27 23:19:34 +08:00
Kubernetes Prow Robot
f7967af3bd
Merge pull request #118633 from sttts/sttts-controlplane-split
...
kube-apiserver: split apart generic control plane options
2023-06-26 13:56:29 -07:00
Dr. Stefan Schimanski
764da8a01d
FIXUP: cmd/kube-apiserver/app/options: split apart controlplane part
2023-06-26 21:50:38 +02:00
Dr. Stefan Schimanski
1b3779baa0
MOVE: cmd/kube-apiserver/app/options: split apart controlplane part
2023-06-26 21:50:37 +02:00
Kubernetes Prow Robot
96d853f4b8
Merge pull request #118870 from SataQiu/kubeadm-clean-v1beta4
...
kubeadm: remove unused Kind and Resource functions from v1beta4 API
2023-06-26 09:40:29 -07:00
SataQiu
4298953c26
kubeadm: remove unused Kind and Resource functions from v1beta4 API
2023-06-26 22:11:52 +08:00
Dr. Stefan Schimanski
6e079545c4
cmd/kube-apiserver: move options completion into options package
2023-06-26 15:20:40 +02:00
Lubomir I. Ivanov
f04484fe77
kubeadm: add the --allow-experimental-api flag to "config" commands
...
Add the flag --allow-experimental-api to the "config migrate" and
"config validate" commands. The flag allows validating / migrating-to
a unreleased / experimental API version.
Add a new experimentalAPIVersions map in validateSupportedVersion()
that contains v1beta4.
2023-06-26 13:50:47 +03:00
Lubomir I. Ivanov
0774f779d5
kubeadm: add v1beta4 to the kubeadm API scheme
...
The highest priority is still v1beta3.
2023-06-26 13:43:47 +03:00
Kubernetes Prow Robot
027ac5a426
Merge pull request #118762 from neolit123/1.28-kubeadm-add-v1beta4-boilerplate
...
kubeadm: add v1beta4 API boilerplate
2023-06-25 22:05:08 -07:00
Kubernetes Prow Robot
4f6a750bbf
Merge pull request #115813 from atiratree/controller-aliases
...
Introduce controller aliases for KCM and CCM
2023-06-22 04:55:39 -07:00
Kubernetes Prow Robot
28296ba59e
Merge pull request #113994 from mengjiao-liu/contextual-logging-controller-certificates
...
certificate controller: use contextual logging
2023-06-21 09:03:42 -07:00
Lubomir I. Ivanov
edb59e9bc7
kubeadm: move token defaulting and related constants to token package
...
Move the defaulting of the BootstrapToken type inside the
bootstraptoken/v1 package. This prevents an error where
codegen complains that a defaulter for the type exists in both
the kubeadm v1beta3 and v1beta4.
Adapt kubeadm code to use the defaulter function and constants
that were moved to bootstraptoken/v1.
NOTE: technically this is a breaking change for direct users of
v1beta3/SetDefaults_BootstrapToken().
2023-06-21 13:34:21 +03:00
Kubernetes Prow Robot
2d60430a16
Merge pull request #118730 from my-git9/ut-features
...
[UT] increase coverage ut for kubeadm/app/features
2023-06-20 07:54:36 -07:00
Lubomir I. Ivanov
eecac05871
kubeadm: add v1beta4 API boilerplate
...
Create v1beta4 by copying v1beta3.
2023-06-20 14:33:30 +03:00
xin.li
180c2332bf
[UT] increase coverage ut for kubeadm/app/features
...
Signed-off-by: xin.li <xin.li@daocloud.io>
2023-06-20 12:57:22 +08:00
Filip Křepinský
85d9339ef8
add KCM names into CCM cmd allowed import-restrictions
2023-06-19 15:01:01 +02:00
Filip Křepinský
4e6a3fb9c1
deduplicate cloud provider controller names
...
and move the to cloud-provider module
2023-06-19 15:01:01 +02:00
Filip Křepinský
e5f5a9bfdb
use controller names for CLI FlagSets to show the names in help
2023-06-19 15:01:01 +02:00
Filip Křepinský
cd56748ec5
reference controllers correctly from CLI help
2023-06-19 15:01:01 +02:00
Filip Křepinský
9fd8f568fe
introduce CCM controller aliases and unify controller names
2023-06-19 15:01:01 +02:00
Filip Křepinský
94792d85de
simplify TestValidateControllersOptions test
2023-06-19 15:00:59 +02:00
Filip Křepinský
9730951136
introduce KCM controller aliases and unify controller names
2023-06-19 14:59:33 +02:00
Lubomir I. Ivanov
ede2ec22b6
kubeadm: drop older etcd versions from kubeadm support
...
- drop versions < 1.22 in the etcd map
- use 3.5.9-0 for >= 1.22 versions
- make the minimum version for external etcd 3.4.13-4 and max 3.5.9-0
- update images_test to not rely on a pinned etcd version in tests
note: the image 3.4.18-0 was never released in registry.k8s.io!
2023-06-18 15:38:53 +03:00
Paco Xu
f44029705f
exit 1 if status are not as expected(order)
...
Signed-off-by: Paco Xu <paco.xu@daocloud.io>
2023-06-18 14:09:50 +08:00
Kubernetes Prow Robot
47e79b8156
Merge pull request #116910 from fatsheep9146/job-controller-contextual-logging
...
Migrated pkg/controller/job to contextual logging
2023-06-14 08:00:18 -07:00
Ziqi Zhao
7bc449d7e0
add contextual logging to job-controller
...
Signed-off-by: Ziqi Zhao <zhaoziqi9146@gmail.com>
2023-06-14 13:40:02 +08:00
carlory
5e048041e4
remove helper function for unused storage feature in pkg/proxy/util
2023-06-13 09:22:59 +08:00
Kubernetes Prow Robot
2353dac98a
Merge pull request #117964 from ytinirt/patch-1
...
Update --image-gc-low-threshold option's description
2023-06-12 13:46:26 -07:00
Kubernetes Prow Robot
32048b1467
Merge pull request #117550 from borgerli/cron-job-syncs
...
add --concurrent-cron-job-syncs flag for kube-controller-manager
2023-06-12 13:46:19 -07:00
Kubernetes Prow Robot
03486cec21
Merge pull request #116530 from pacoxu/undepreated-provider-id
...
undeprecate kubelet --provider-id flag
2023-06-12 13:45:58 -07:00
Kubernetes Prow Robot
49d7b3f0a0
Merge pull request #118596 from SataQiu/fix-kubelet-20230610
...
kubelet: mark '--azure-container-registry-config' flag as deprecated
2023-06-12 12:44:10 -07:00
Kubernetes Prow Robot
8a0b1bbf24
Merge pull request #118095 from carlory/patch-002
...
remove unused pv informer from expand_controller
2023-06-12 11:43:58 -07:00
SataQiu
910630fbea
kubelet: mark '--azure-container-registry-config' flag as deprecated
2023-06-10 00:52:24 +08:00
Kubernetes Prow Robot
b2042d6ce4
Merge pull request #118338 from aroradaman/mv-ipset
...
move pkg/util/ipset inside pkg/proxy/ipvs
2023-06-09 08:14:24 -07:00
Kubernetes Prow Robot
577d524f08
Merge pull request #118513 from danwinship/proxy-node-ip
...
kube-proxy startup node IP detection
2023-06-08 17:30:12 -07:00
Kubernetes Prow Robot
de7360d9bc
Merge pull request #118115 from TommyStarK/gh_118090
...
kube-proxy: remove log warning about not using config file
2023-06-08 15:40:24 -07:00
Kubernetes Prow Robot
7ef5ec499d
Merge pull request #117029 from Rajalakshmi-Girish/prune-junit-xml
...
Add flag to prune PASSED subtests in junit xml and have top level tests
2023-06-07 06:18:24 -07:00
Dr. Stefan Schimanski
77cf37ee54
STRUCTURE: cmd/kube-apiserver: move admission construction back from controlplane
2023-06-07 10:11:04 +03:00
Dr. Stefan Schimanski
7961812bed
STRUCTURE: cmd/kube-apiserver: move OpenAPI construction back from controlplane
2023-06-07 10:11:04 +03:00
Dr. Stefan Schimanski
43be9c3a0a
MOVE: cmd/kube-apiserver: move genericapiserver construction into controlplane package
2023-06-07 10:11:04 +03:00
Dr. Stefan Schimanski
9be6e7bb33
STRUCTURE: cmd/kube-apiserver/app: stratify construction with options/config/server
2023-06-07 10:05:43 +03:00
Dr. Stefan Schimanski
e6ed4c7934
CLEANUP: cmd/kube-apiserver/app: remove trivial funcs
2023-06-07 10:05:43 +03:00
Dr. Stefan Schimanski
f7d4e90b5c
MOVE: cmd/kube-apiserver/app.createAPIExtensionsConfig -> pkg/controlplane
2023-06-07 10:05:43 +03:00
Dan Winship
4962e6eacb
Squash detectNodeIP and nodeIPTuple together
2023-06-06 20:48:00 -04:00
Dan Winship
b69b34bec6
Move a kube-proxy unit test to the correct file
2023-06-06 16:01:03 -04:00
Kubernetes Prow Robot
5a5ebfd88b
Merge pull request #118499 from aojea/kproxy_podcidr_alt
...
kube-proxy avoid race condition using LocalModeNodeCIDR
2023-06-06 12:18:11 -07:00
Kubernetes Prow Robot
6f116dc4d5
Merge pull request #118416 from sttts/sttts-etcd-options-complete
...
k8s.io/apiserver: remove skewed completion from EtcdOptions
2023-06-06 09:20:22 -07:00
Antonio Ojea
26801d6541
kube-proxy avoid race condition using LocalModeNodeCIDR
...
Since kube-proxy in LocalModeNodeCIDR needs to obtain the PodCIDR
assigned to the node it watches for the Node object.
However, kube-proxy startup process requires to have these watches in
different places, that opens the possibility of having a race condition
if the same node is recreated and a different PodCIDR is assigned.
Initializing the second watch with the value obtained in the first one
allows us to detect this situation.
Change-Id: I6adeedb6914ad2afd3e0694dcab619c2a66135f8
Signed-off-by: Antonio Ojea <aojea@google.com>
2023-06-06 15:03:22 +00:00
Rajalakshmi Girish
dddbecb47e
prune's xml files to display only top level tests and failed sub-tests
2023-06-06 05:26:00 -07:00
Dr. Stefan Schimanski
e9e4acb1dd
k8s.io/apiserver: remove skewed completion from EtcdOptions
2023-06-06 08:32:34 +03:00
cyclinder
8e4228a8c1
remove CSI-migration gate
2023-06-04 18:40:17 +08:00
Dr. Stefan Schimanski
f351c6d1ec
k8s.io/apiserver: apply storage object count tracker implicitly
2023-06-02 20:24:06 +02:00
Kubernetes Prow Robot
2eb4eac581
Merge pull request #118353 from SataQiu/fix-kubeadm-test-20230531
...
kubeadm: add command-line integration test to ensure that the supported etcd version is always available for the stable Kubernetes version
2023-06-02 04:40:53 -07:00
Andy Zhang
1ce285ad3d
Revert "removed the deprecated azureFile
in-tree storage plugin"
2023-06-02 10:20:53 +08:00
SataQiu
daa7115907
kubeadm: add deprecation message for UpgradeAddonsBeforeControlPlane feature gate
2023-06-01 23:06:26 +08:00
Kubernetes Prow Robot
33a2438de9
Merge pull request #118341 from pacoxu/add-pacoxu-kubeadm
...
add pacoxu to kubeadm approvers
2023-06-01 04:33:46 -07:00
SataQiu
d49c43abde
kubeadm: add integration test to ensure that the supported etcd version is always available for the stable Kubernetes version
2023-06-01 18:45:06 +08:00
TommyStarK
db2389ba9c
kube-proxy: remove log warning about not using config file
...
Signed-off-by: TommyStarK <thomasmilox@gmail.com>
2023-06-01 11:48:16 +02:00
Kubernetes Prow Robot
23698d3e9f
Merge pull request #118335 from pacoxu/revert-118316-fix-kubeadm-20230529
...
Revert "kubeadm: add --feature-gates flag for kubeadm upgrade node"
2023-05-31 02:01:57 -07:00
Paco Xu
f2a5e247eb
add pacoxu to kubeadm approvers list
2023-05-31 10:34:42 +08:00
Daman Arora
2d8c820741
move pkg/util/ipset inside pkg/proxy/ipvs
...
Signed-off-by: Daman Arora <aroradaman@gmail.com>
2023-05-31 00:30:20 +05:30
Kubernetes Prow Robot
9a40920c06
Merge pull request #118296 from uablrek/remove-moby-ipvs
...
Move pkg/util/ipvs inside pkg/proxy/ipvs
2023-05-30 10:14:02 -07:00
Paco Xu
85e0d8c8b1
Revert "kubeadm: add --feature-gates flag for kubeadm upgrade node"
2023-05-31 00:30:08 +08:00
Kubernetes Prow Robot
320d915897
Merge pull request #118316 from SataQiu/fix-kubeadm-20230529
...
kubeadm: add --feature-gates flag for kubeadm upgrade node
2023-05-29 13:01:43 -07:00