Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use port forwarding on Linux with Docker Desktop #15126

Merged
merged 3 commits into from
Oct 25, 2022

Conversation

spowelljr
Copy link
Member

Fixes #14202

Detects if the user is using Docker Desktop on Linux and requires port forwarding if they are.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Oct 12, 2022
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Oct 12, 2022
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Oct 12, 2022
@spowelljr
Copy link
Member Author

/ok-to-test

@k8s-ci-robot k8s-ci-robot added the ok-to-test Indicates a non-member PR verified by an org member that is safe to test. label Oct 12, 2022
@minikube-pr-bot
Copy link

kvm2 driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 15126) |
+----------------+----------+---------------------+
| minikube start | 59.1s    | 58.6s               |
| enable ingress | 31.1s    | 31.2s               |
+----------------+----------+---------------------+

Times for minikube ingress: 31.4s 30.9s 30.9s 31.4s 30.9s
Times for minikube (PR 15126) ingress: 30.8s 30.9s 29.9s 31.4s 32.8s

Times for minikube (PR 15126) start: 58.8s 57.3s 58.6s 58.3s 60.1s
Times for minikube start: 60.0s 58.5s 59.9s 58.5s 58.6s

docker driver with docker runtime

+-------------------+----------+---------------------+
|      COMMAND      | MINIKUBE | MINIKUBE (PR 15126) |
+-------------------+----------+---------------------+
| minikube start    | 31.2s    | 31.9s               |
| ⚠️  enable ingress | 22.2s    | 34.5s ⚠️             |
+-------------------+----------+---------------------+

Times for minikube start: 32.8s 29.9s 31.1s 32.4s 29.9s
Times for minikube (PR 15126) start: 31.6s 33.9s 29.2s 32.2s 32.5s

Times for minikube ingress: 22.1s 21.6s 22.1s 22.1s 23.1s
Times for minikube (PR 15126) ingress: 21.7s 82.6s 23.1s 23.1s 22.1s

docker driver with containerd runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 15126) |
+----------------+----------+---------------------+
| minikube start | 34.7s    | 28.4s               |
| enable ingress | 27.8s    | 27.6s               |
+----------------+----------+---------------------+

Times for minikube (PR 15126) start: 36.3s 27.5s 25.4s 24.9s 27.9s
Times for minikube start: 29.1s 40.3s 38.7s 39.8s 25.5s

Times for minikube (PR 15126) ingress: 28.1s 27.1s 28.1s 28.1s 26.6s
Times for minikube ingress: 27.1s 27.6s 28.0s 28.1s 28.1s

@minikube-pr-bot
Copy link

These are the flake rates of all failed tests.

Environment Failed Tests Flake Rate (%)
Docker_Linux TestNetworkPlugins/group/auto/DNS (gopogh) 1.88 (chart)
Docker_Linux TestNetworkPlugins/group/kindnet/Start (gopogh) 1.88 (chart)
Docker_macOS TestMultiNode/serial/RestartKeepsNodes (gopogh) 41.29 (chart)
Docker_Windows TestNetworkPlugins/group/false/DNS (gopogh) 50.00 (chart)
KVM_Linux TestMultiNode/serial/RestartMultiNode (gopogh) 50.30 (chart)
Docker_Windows TestNoKubernetes/serial/StartWithStopK8s (gopogh) 51.35 (chart)
Docker_Windows TestMultiNode/serial/StartAfterStop (gopogh) 53.38 (chart)
KVM_Linux_containerd TestPreload (gopogh) 53.94 (chart)
Docker_Linux_containerd TestPreload (gopogh) 66.08 (chart)
Docker_Windows TestNetworkPlugins/group/bridge/DNS (gopogh) 66.67 (chart)
Docker_Linux_containerd TestNetworkPlugins/group/calico/Start (gopogh) 78.51 (chart)
Docker_Linux_containerd TestNetworkPlugins/group/enable-default-cni/DNS (gopogh) 81.10 (chart)
Hyper-V_Windows TestPause/serial/PauseAgain (gopogh) 81.75 (chart)
Docker_Linux TestNetworkPlugins/group/enable-default-cni/DNS (gopogh) 85.00 (chart)
Docker_Linux_containerd TestNetworkPlugins/group/bridge/DNS (gopogh) 85.07 (chart)
Docker_Linux TestNetworkPlugins/group/bridge/DNS (gopogh) 85.62 (chart)
Docker_Linux TestNetworkPlugins/group/kubenet/DNS (gopogh) 87.50 (chart)
Docker_Linux TestNetworkPlugins/group/false/DNS (gopogh) 91.25 (chart)
Docker_Linux_containerd TestKubernetesUpgrade (gopogh) 100.00 (chart)
Docker_Linux TestNetworkPlugins/group/calico/DNS (gopogh) 100.00 (chart)
Docker_macOS TestIngressAddonLegacy/serial/ValidateIngressAddonActivation (gopogh) 100.00 (chart)
Docker_macOS TestIngressAddonLegacy/serial/ValidateIngressAddons (gopogh) 100.00 (chart)
Docker_macOS TestIngressAddonLegacy/serial/ValidateIngressDNSAddonActivation (gopogh) 100.00 (chart)
Docker_macOS TestIngressAddonLegacy/StartLegacyK8sCluster (gopogh) 100.00 (chart)
Docker_macOS TestKubernetesUpgrade (gopogh) 100.00 (chart)
Docker_macOS TestMissingContainerUpgrade (gopogh) 100.00 (chart)
Docker_macOS TestNetworkPlugins/group/kubenet/HairPin (gopogh) 100.00 (chart)
Docker_macOS TestRunningBinaryUpgrade (gopogh) 100.00 (chart)
Docker_macOS TestStartStop/group/old-k8s-version/serial/AddonExistsAfterStop (gopogh) 100.00 (chart)
Docker_macOS TestStartStop/group/old-k8s-version/serial/DeployApp (gopogh) 100.00 (chart)
More tests... Continued...

Too many tests failed - See test logs for more details.

To see the flake rates of all tests by environment, click here.

@@ -35,6 +35,7 @@ type SysInfo struct {
Rootless bool // Weather or not the docker is running on rootless mode
StorageDriver string // the storage driver for the daemon (for example overlay2)
Errors []string // any server issues
DockerOS string // used to detect if using Docker Desktop or Docker Engine on Linux
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is OS short for here?

Copy link
Member Author

@spowelljr spowelljr Oct 18, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Operating System, Docker detects the OS, if it's Docker Engine it lists the machines actual OS (Debian, Ubuntu, etc.) but if it's Docker Desktop it lists the OS as Docker Desktop.

@@ -611,6 +611,9 @@ func generateNewConfigFromFlags(cmd *cobra.Command, k8sVersion string, rtime str
klog.Info("auto-setting LocalStorageCapacityIsolation to false because using btrfs storage driver")
cc.KubernetesConfig.FeatureGates = addFeatureGate(cc.KubernetesConfig.FeatureGates, "LocalStorageCapacityIsolation=false")
}
if runtime.GOOS == "linux" && si.DockerOS == "Docker Desktop" {
out.WarningT("For an improved experience it's recommended to use Docker Engine over Docker Desktop")
Copy link
Member

@medyagh medyagh Oct 18, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of ...

also consider adding a todo: follow up add page to site or a link to show users how to install docker-engine instead of docker desktop

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update message to include a link to Docker Engine install

@minikube-pr-bot
Copy link

kvm2 driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 15126) |
+----------------+----------+---------------------+
| minikube start | 55.4s    | 56.1s               |
| enable ingress | 28.0s    | 26.5s               |
+----------------+----------+---------------------+

Times for minikube start: 54.2s 55.5s 55.5s 54.6s 57.1s
Times for minikube (PR 15126) start: 55.1s 54.9s 58.3s 56.1s 56.0s

Times for minikube ingress: 26.1s 28.6s 29.1s 28.1s 28.2s
Times for minikube (PR 15126) ingress: 25.1s 25.6s 28.6s 25.1s 28.1s

docker driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 15126) |
+----------------+----------+---------------------+
| minikube start | 28.1s    | 27.9s               |
| enable ingress | 23.7s    | 23.4s               |
+----------------+----------+---------------------+

Times for minikube start: 28.7s 27.7s 26.5s 26.7s 31.0s
Times for minikube (PR 15126) start: 27.2s 29.3s 28.0s 27.5s 27.8s

Times for minikube (PR 15126) ingress: 26.5s 23.0s 22.9s 22.0s 22.5s
Times for minikube ingress: 23.0s 23.5s 23.0s 22.5s 26.5s

docker driver with containerd runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 15126) |
+----------------+----------+---------------------+
| minikube start | 23.2s    | 23.3s               |
| enable ingress | 27.4s    | 29.2s               |
+----------------+----------+---------------------+

Times for minikube (PR 15126) ingress: 27.0s 27.0s 27.0s 27.4s 37.5s
Times for minikube ingress: 27.0s 27.5s 27.5s 27.5s 27.4s

Times for minikube start: 23.4s 23.1s 22.6s 23.7s 23.2s
Times for minikube (PR 15126) start: 23.7s 23.4s 23.2s 22.9s 23.2s

@minikube-pr-bot
Copy link

These are the flake rates of all failed tests.

Environment Failed Tests Flake Rate (%)
Docker_Linux_containerd TestNetworkPlugins/group/auto/DNS (gopogh) 0.90 (chart)
Hyperkit_macOS TestMultiNode/serial/RestartMultiNode (gopogh) 1.38 (chart)
Docker_Linux_containerd TestPause/serial/Start (gopogh) 24.52 (chart)
Docker_Linux_containerd TestOffline (gopogh) 27.74 (chart)
Docker_Linux_containerd TestAddons/Setup (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/DashboardCmd (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/MountCmd/any-port (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/MySQL (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/PersistentVolumeClaim (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/ServiceCmd (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/ServiceCmdConnect (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/TunnelCmd/serial/AccessDirect (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/parallel/TunnelCmd/serial/WaitService/Setup (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/serial/ExtraConfig (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/serial/SoftStart (gopogh) 28.39 (chart)
Docker_Linux_containerd TestFunctional/serial/StartWithProxy (gopogh) 28.39 (chart)
Docker_Linux_containerd TestIngressAddonLegacy/serial/ValidateIngressAddonActivation (gopogh) 28.39 (chart)
Docker_Linux_containerd TestIngressAddonLegacy/StartLegacyK8sCluster (gopogh) 28.39 (chart)
Docker_Linux_containerd TestJSONOutput/start/Command (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/AddNode (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/DeleteNode (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/DeployApp2Nodes (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/FreshStart2Nodes (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/PingHostFrom2Pods (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/ProfileList (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/StartAfterStop (gopogh) 28.39 (chart)
Docker_Linux_containerd TestMultiNode/serial/StopNode (gopogh) 28.39 (chart)
Hyperkit_macOS TestPause/serial/SecondStartNoReconfiguration (gopogh) 28.97 (chart)
Docker_Linux_containerd TestMultiNode/serial/RestartMultiNode (gopogh) 30.32 (chart)
Docker_Linux_containerd TestMultiNode/serial/RestartKeepsNodes (gopogh) 30.97 (chart)
More tests... Continued...

Too many tests failed - See test logs for more details.

To see the flake rates of all tests by environment, click here.

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: medyagh, spowelljr

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@spowelljr spowelljr merged commit 253c006 into kubernetes:master Oct 25, 2022
@spowelljr spowelljr deleted the dockerDesktopLinux branch October 25, 2022 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

minikube on driver docker not running using docker desktop vm
4 participants