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

fix(image-repository): allow subdomains with numbers #17496

Merged
merged 1 commit into from
Mar 19, 2024
Merged

fix(image-repository): allow subdomains with numbers #17496

merged 1 commit into from
Mar 19, 2024

Conversation

justinmchase
Copy link
Contributor

My company blocks docker.io at the network level and there is no proxy solution. Instead they provide an Artifactory registry which mirrors all of docker.io.

Thus I am attempting to run:

minikube start --image-repository docker.repo1.uhc.com

Which fails with the error:

E1025 20:07:14.125831 12982 start.go:1541] Provided repository is not a valid URL. Defaulting to "auto"

The URL is indeed valid and so I tracked the issue down to the line of code in this PR which appears to assume that only the bottom level subdomain may contain numbers, which is a bad assumption.

I used regexr.com to validate:

before

Screenshot 2023-10-25 at 8 20 37 PM

after

Screenshot 2023-10-25 at 8 20 46 PM

@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Oct 26, 2023

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: justinmchase / name: Justin Chase (410000e)

@k8s-ci-robot k8s-ci-robot added the cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. label Oct 26, 2023
@k8s-ci-robot
Copy link
Contributor

Welcome @justinmchase!

It looks like this is your first PR to kubernetes/minikube 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes/minikube has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot
Copy link
Contributor

Hi @justinmchase. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Oct 26, 2023
@minikube-bot
Copy link
Collaborator

Can one of the admins verify this patch?

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Oct 26, 2023
cmd/minikube/cmd/start.go Show resolved Hide resolved
@justinmchase
Copy link
Contributor Author

Can we re-run the tests? I believe the requested change has been met.

@justinmchase justinmchase requested a review from medyagh November 8, 2023 14:31
@justinmchase
Copy link
Contributor Author

@medyagh can you re-review this one? I made the requested changes.

@liangyuanpeng
Copy link
Contributor

I also need this PR. Please help to see what we are missing.

/cc @medyagh @spowelljr
/kind bug

@k8s-ci-robot k8s-ci-robot requested a review from spowelljr January 9, 2024 14:28
@k8s-ci-robot k8s-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Jan 9, 2024
@medyagh
Copy link
Member

medyagh commented Mar 16, 2024

thank you @justinmchase for your patience, I saw there is also a newer PR
https://github.com/kubernetes/minikube/pull/18290/files

but since your PR was first, if you include the test cases from the other PR int his PR we could merge yours!

this bug fix will be included in the next release

@medyagh
Copy link
Member

medyagh commented Mar 16, 2024

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Mar 16, 2024
@minikube-pr-bot

This comment has been minimized.

@minikube-pr-bot

This comment has been minimized.

@allenhaozi
Copy link

thank you @justinmchase for your patience, I saw there is also a newer PR https://github.com/kubernetes/minikube/pull/18290/files

but since your PR was first, if you include the test cases from the other PR int his PR we could merge yours!

this bug fix will be included in the next release

I did not see this pr when I submitted. hi @justinmchase iIf it is convenient for you to add more test cases
, I will close my pr

/cc @liangyuanpeng @medyagh

@justinmchase
Copy link
Contributor Author

I'll get on that today then.

@k8s-ci-robot k8s-ci-robot removed the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Mar 18, 2024
@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Mar 18, 2024
@justinmchase
Copy link
Contributor Author

justinmchase commented Mar 18, 2024

@medyagh I rebased my pr from upstream master and added the additional test cases from #18290.

@justinmchase
Copy link
Contributor Author

My company is currently evaluating alternatives to Docker desktop and this is blocking us from using minikube so I would definitely appreciate including this! Thank you.

@minikube-pr-bot
Copy link

kvm2 driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 17496) |
+----------------+----------+---------------------+
| minikube start | 51.6s    | 51.7s               |
| enable ingress | 23.5s    | 25.0s               |
+----------------+----------+---------------------+

Times for minikube start: 51.1s 52.7s 50.2s 52.3s 51.7s
Times for minikube (PR 17496) start: 50.3s 51.5s 53.1s 51.8s 51.9s

Times for minikube ingress: 22.6s 22.5s 23.1s 23.1s 26.0s
Times for minikube (PR 17496) ingress: 23.1s 23.1s 25.6s 27.1s 26.1s

docker driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 17496) |
+----------------+----------+---------------------+
| minikube start | 23.4s    | 24.4s               |
| enable ingress | 20.4s    | 20.1s               |
+----------------+----------+---------------------+

Times for minikube ingress: 20.3s 19.3s 21.3s 20.3s 20.8s
Times for minikube (PR 17496) ingress: 20.8s 19.3s 19.8s 20.3s 20.3s

Times for minikube start: 22.9s 26.3s 22.7s 22.3s 22.6s
Times for minikube (PR 17496) start: 22.9s 25.9s 25.5s 23.0s 24.8s

docker driver with containerd runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 17496) |
+----------------+----------+---------------------+
| minikube start | 21.7s    | 22.6s               |
| enable ingress | 33.7s    | 30.7s               |
+----------------+----------+---------------------+

Times for minikube ingress: 45.8s 29.8s 29.8s 30.8s 32.3s
Times for minikube (PR 17496) ingress: 32.3s 29.8s 30.8s 30.8s 29.8s

Times for minikube start: 24.1s 21.6s 21.7s 20.2s 21.0s
Times for minikube (PR 17496) start: 24.0s 21.2s 23.7s 23.1s 21.1s

@minikube-pr-bot
Copy link

These are the flake rates of all failed tests.

Environment Failed Tests Flake Rate (%)
KVM_Linux_crio TestFunctional/parallel/ImageCommands/ImageLoadDaemon (gopogh) 6.71 (chart)
Hyperkit_macOS TestErrorSpam/setup (gopogh) 28.57 (chart)
Hyperkit_macOS TestCertExpiration (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/parallel/CpCmd (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/parallel/SSHCmd (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/CacheCmd/cache/cache_reload (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/CacheCmd/cache/verify_cache_inside_node (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/KubeContext (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/KubectlGetPods (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/LogsCmd (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/LogsFileCmd (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/MinikubeKubectlCmd (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/MinikubeKubectlCmdDirectly (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/SoftStart (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/serial/StartWithProxy (gopogh) 32.14 (chart)
Hyperkit_macOS TestImageBuild/serial/Setup (gopogh) 32.14 (chart)
Hyperkit_macOS TestJSONOutput/start/parallel/DistinctCurrentSteps (gopogh) 32.14 (chart)
Hyperkit_macOS TestJSONOutput/start/parallel/IncreasingCurrentSteps (gopogh) 32.14 (chart)
Hyperkit_macOS TestMountStart/serial/StartWithMountFirst (gopogh) 32.14 (chart)
Hyperkit_macOS TestMultiNode/serial/MultiNodeLabels (gopogh) 32.14 (chart)
Hyperkit_macOS TestMultiNode/serial/ProfileList (gopogh) 32.14 (chart)
Hyperkit_macOS TestNetworkPlugins/group/kubenet/Start (gopogh) 32.14 (chart)
Hyperkit_macOS TestPause/serial/Start (gopogh) 32.14 (chart)
Hyperkit_macOS TestSkaffold (gopogh) 32.14 (chart)
Hyperkit_macOS TestStoppedBinaryUpgrade/MinikubeLogs (gopogh) 32.14 (chart)
Hyperkit_macOS TestStoppedBinaryUpgrade/Upgrade (gopogh) 32.14 (chart)
Hyperkit_macOS TestFunctional/parallel/UpdateContextCmd/no_changes (gopogh) 32.53 (chart)
Hyperkit_macOS TestFunctional/parallel/UpdateContextCmd/no_minikube_cluster (gopogh) 32.53 (chart)
Hyperkit_macOS TestCertOptions (gopogh) 33.33 (chart)
Hyperkit_macOS TestDockerFlags (gopogh) 33.33 (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.

@spowelljr spowelljr merged commit 3e67840 into kubernetes:master Mar 19, 2024
24 of 38 checks passed
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: justinmchase, 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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 19, 2024
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. kind/bug Categorizes issue or PR as related to a bug. 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.

8 participants