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

Replace ReplicationController with Deployment in addons #19254

Conversation

Razorr1996
Copy link
Contributor

@Razorr1996 Razorr1996 commented Jul 15, 2024

fixes #18954

Minikube outputs:
Creating minikube cluster:

❯ ./out/minikube-darwin-arm64 -v=2 start
😄  minikube v1.33.1 on Darwin 14.5 (arm64)
✨  Automatically selected the docker driver. Other choices: parallels, ssh
📌  Using Docker Desktop driver with root privileges
👍  Starting "minikube" primary control-plane node in "minikube" cluster
🚜  Pulling base image v0.0.44-1720578864-19219 ...
❗  minikube was unable to download gcr.io/k8s-minikube/kicbase-builds:v0.0.44-1720578864-19219, but successfully downloaded docker.io/kicbase/build:v0.0.44-1720578864-19219 as a fallback image
🔥  Creating docker container (CPUs=2, Memory=7892MB) ...
🐳  Preparing Kubernetes v1.30.2 on Docker 27.0.3 ...
    ▪ Generating certificates and keys ...
    ▪ Booting up control plane ...
    ▪ Configuring RBAC rules ...
🔗  Configuring bridge CNI (Container Networking Interface) ...
🔎  Verifying Kubernetes components...
    ▪ Using image gcr.io/k8s-minikube/storage-provisioner:v5
🌟  Enabled addons: storage-provisioner, default-storageclass
🏄  Done! kubectl is now configured to use "minikube" cluster and "default" namespace by default

Enabling registry addon:

❯ ./out/minikube-darwin-arm64 -v=2 addons enable registry
💡  registry is an addon maintained by minikube. For any concerns contact minikube on GitHub.
You can view the list of minikube maintainers at: https://github.com/kubernetes/minikube/blob/master/OWNERS
╭──────────────────────────────────────────────────────────────────────────────────────────────────────╮
│                                                                                                      │
│    Registry addon with docker driver uses port 56089 please use that instead of default port 5000    │
│                                                                                                      │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────╯
📘  For more information see: https://minikube.sigs.k8s.io/docs/drivers/docker
    ▪ Using image docker.io/registry:2.8.3
    ▪ Using image gcr.io/k8s-minikube/kube-registry-proxy:0.0.6
🔎  Verifying registry addon...
🌟  The 'registry' addon is enabled

Describe registry deployment:

❯ kubectl -n kube-system describe deployments.apps registry
Name:                   registry
Namespace:              kube-system
CreationTimestamp:      Tue, 16 Jul 2024 22:13:23 +0200
Labels:                 addonmanager.kubernetes.io/mode=Reconcile
                        kubernetes.io/minikube-addons=registry
Annotations:            deployment.kubernetes.io/revision: 1
Selector:               addonmanager.kubernetes.io/mode=Reconcile,kubernetes.io/minikube-addons=registry
Replicas:               1 desired | 1 updated | 1 total | 1 available | 0 unavailable
StrategyType:           RollingUpdate
MinReadySeconds:        0
RollingUpdateStrategy:  25% max unavailable, 25% max surge
Pod Template:
  Labels:  actual-registry=true
           addonmanager.kubernetes.io/mode=Reconcile
           kubernetes.io/minikube-addons=registry
  Containers:
   registry:
    Image:      docker.io/registry:2.8.3@sha256:79b29591e1601a73f03fcd413e655b72b9abfae5a23f1ad2e883d4942fbb4351
    Port:       5000/TCP
    Host Port:  0/TCP
    Environment:
      REGISTRY_STORAGE_DELETE_ENABLED:  true
    Mounts:                             <none>
  Volumes:                              <none>
  Node-Selectors:                       <none>
  Tolerations:                          <none>
Conditions:
  Type           Status  Reason
  ----           ------  ------
  Available      True    MinimumReplicasAvailable
  Progressing    True    NewReplicaSetAvailable
OldReplicaSets:  <none>
NewReplicaSet:   registry-656c9c8d9c (1/1 replicas created)
Events:
  Type    Reason             Age   From                   Message
  ----    ------             ----  ----                   -------
  Normal  ScalingReplicaSet  54s   deployment-controller  Scaled up replica set registry-656c9c8d9c to 1

Describe registry service:

❯ kubectl -n kube-system describe svc registry
Name:              registry
Namespace:         kube-system
Labels:            addonmanager.kubernetes.io/mode=Reconcile
                   kubernetes.io/minikube-addons=registry
Annotations:       <none>
Selector:          actual-registry=true,kubernetes.io/minikube-addons=registry
Type:              ClusterIP
IP Family Policy:  SingleStack
IP Families:       IPv4
IP:                10.102.137.10
IPs:               10.102.137.10
Port:              http  80/TCP
TargetPort:        5000/TCP
Endpoints:         10.244.0.3:5000
Port:              https  443/TCP
TargetPort:        443/TCP
Endpoints:         10.244.0.3:443
Session Affinity:  None
Events:            <none>

Enabling efk addon:

❯ ./out/minikube-darwin-arm64 -v=2 addons enable efk

❌  Exiting due to MK_ADDON_ENABLE: The current images used in the efk addon contain Log4j vulnerabilities, the addon will be disabled until images are updated, see: https://github.com/kubernetes/minikube/issues/15280

Enabling freshpod addon:

❯ ./out/minikube-darwin-arm64 -v=2 addons enable freshpod
💡  freshpod is an addon maintained by Google. For any concerns contact minikube on GitHub.
You can view the list of minikube maintainers at: https://github.com/kubernetes/minikube/blob/master/OWNERS
    ▪ Using image gcr.io/google-samples/freshpod:v0.0.1
🌟  The 'freshpod' addon is enabled

Describe freshpod service:

❯ kubectl -n kube-system describe deployments.apps freshpod
Name:                   freshpod
Namespace:              kube-system
CreationTimestamp:      Tue, 16 Jul 2024 22:16:34 +0200
Labels:                 addonmanager.kubernetes.io/mode=Reconcile
                        k8s-app=freshpod
                        kubernetes.io/minikube-addons=freshpod
Annotations:            deployment.kubernetes.io/revision: 1
Selector:               addonmanager.kubernetes.io/mode=Reconcile,k8s-app=freshpod,kubernetes.io/minikube-addons=freshpod
Replicas:               1 desired | 1 updated | 1 total | 1 available | 0 unavailable
StrategyType:           RollingUpdate
MinReadySeconds:        0
RollingUpdateStrategy:  25% max unavailable, 25% max surge
Pod Template:
  Labels:  addonmanager.kubernetes.io/mode=Reconcile
           k8s-app=freshpod
           kubernetes.io/minikube-addons=freshpod
  Containers:
   freshpod:
    Image:        gcr.io/google-samples/freshpod:v0.0.1@sha256:b9efde5b509da3fd2959519c4147b653d0c5cefe8a00314e2888e35ecbcb46f9
    Port:         <none>
    Host Port:    <none>
    Environment:  <none>
    Mounts:
      /var/run/docker.sock from docker (rw)
  Volumes:
   docker:
    Type:          HostPath (bare host directory volume)
    Path:          /var/run/docker.sock
    HostPathType:  Socket
  Node-Selectors:  <none>
  Tolerations:     <none>
Conditions:
  Type           Status  Reason
  ----           ------  ------
  Available      True    MinimumReplicasAvailable
  Progressing    True    NewReplicaSetAvailable
OldReplicaSets:  <none>
NewReplicaSet:   freshpod-78fc8bbbf4 (1/1 replicas created)
Events:
  Type    Reason             Age   From                   Message
  ----    ------             ----  ----                   -------
  Normal  ScalingReplicaSet  74s   deployment-controller  Scaled up replica set freshpod-78fc8bbbf4 to 1

Copy link

linux-foundation-easycla bot commented Jul 15, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: spowelljr / name: Steven Powell (a90d01c)
  • ✅ login: Razorr1996 / name: Artem Basalaev (3d95b37)

@k8s-ci-robot k8s-ci-robot added the cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. label Jul 15, 2024
@minikube-bot
Copy link
Collaborator

Can one of the admins verify this patch?

@k8s-ci-robot
Copy link
Contributor

Welcome @Razorr1996!

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 k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jul 15, 2024
@k8s-ci-robot
Copy link
Contributor

Hi @Razorr1996. 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-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. 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 Jul 15, 2024
@spowelljr
Copy link
Member

/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 Jul 15, 2024
@medyagh
Copy link
Member

medyagh commented Jul 15, 2024

@Razorr1996 do you mind sharing the output of minikube after enabling those addons in the PR description ? just to verify it doesnt break anything

@minikube-pr-bot

This comment has been minimized.

@Razorr1996
Copy link
Contributor Author

@medyagh Thank you for feedback. Yes, I added output from updated version compiled locally and using -v=2 logging:

  1. Creating new cluster — looks good as usual
  2. Enabling registry addon with describing new deployment and service
  3. Enabling efk addon — internal block due to efk addon image contains Log4j CVEs #15280
  4. Enabling freshpod addon with describing new deployment

Can you check it?

@spowelljr spowelljr added kind/failing-test Categorizes issue or PR as related to a consistently or frequently failing test. do-not-merge/failing-test Indicates that a PR should not merge because it has a failing test and removed kind/failing-test Categorizes issue or PR as related to a consistently or frequently failing test. labels Jul 16, 2024
@spowelljr
Copy link
Member

spowelljr commented Jul 16, 2024

Hi @Razorr1996, it looks like it's failing the Registry addon test in all environments, you can see the below link for the test failure.

https://storage.googleapis.com/minikube-builds/logs/19254/35345/Docker_Linux.html#fail_TestAddons%2fparallel%2fRegistry

It's failing on minikube addons disable registry which is odd, I'll try taking a quick look into it myself

@spowelljr
Copy link
Member

spowelljr commented Jul 16, 2024

Ah, I found it, in only the registry addon test we had a check waiting the the replica controller to stabilize, but since it's no longer an RC it failed, so updated it to wait for the deployment

@spowelljr spowelljr removed the do-not-merge/failing-test Indicates that a PR should not merge because it has a failing test label Jul 16, 2024
@spowelljr
Copy link
Member

/retest-this-please

@minikube-pr-bot
Copy link

kvm2 driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 19254) |
+----------------+----------+---------------------+
| minikube start | 50.1s    | 49.1s               |
| enable ingress | 25.1s    | 24.9s               |
+----------------+----------+---------------------+

Times for minikube start: 48.5s 50.2s 48.4s 50.8s 52.8s
Times for minikube (PR 19254) start: 51.8s 49.0s 48.2s 46.9s 49.6s

Times for minikube (PR 19254) ingress: 24.0s 24.5s 23.9s 28.0s 24.0s
Times for minikube ingress: 25.9s 23.9s 27.9s 23.5s 24.0s

docker driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 19254) |
+----------------+----------+---------------------+
| minikube start | 22.8s    | 22.4s               |
| enable ingress | 21.2s    | 21.6s               |
+----------------+----------+---------------------+

Times for minikube start: 24.0s 20.7s 21.2s 23.7s 24.2s
Times for minikube (PR 19254) start: 24.6s 21.2s 23.9s 20.7s 21.6s

Times for minikube ingress: 20.7s 21.8s 20.7s 20.8s 21.7s
Times for minikube (PR 19254) ingress: 21.3s 21.3s 21.8s 21.8s 21.8s

docker driver with containerd runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 19254) |
+----------------+----------+---------------------+
| minikube start | 21.8s    | 21.0s               |
| enable ingress | 43.8s    | 47.8s               |
+----------------+----------+---------------------+

Times for minikube start: 22.6s 22.2s 23.4s 20.2s 20.4s
Times for minikube (PR 19254) start: 20.0s 19.3s 20.0s 22.8s 22.5s

Times for minikube ingress: 37.4s 49.3s 36.3s 49.2s 46.8s
Times for minikube (PR 19254) ingress: 47.7s 47.8s 48.2s 47.2s 48.2s

@minikube-pr-bot
Copy link

Here are the number of top 10 failed tests in each environments with lowest flake rate.

Environment Test Name Flake Rate
Docker_Windows (5 failed) TestPause/serial/PauseAgain(gopogh) 0.00% (chart)
KVM_Linux_crio (10 failed) TestStartStop/group/default-k8s-diff-port/serial/SecondStart(gopogh) 3.10% (chart)
KVM_Linux_crio (10 failed) TestAddons/Setup(gopogh) 16.23% (chart)
Docker_Linux_containerd (1 failed) TestAddons/parallel/CSI(gopogh) 0.64% (chart)

Besides the following environments also have failed tests:

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

Copy link
Member

@spowelljr spowelljr left a comment

Choose a reason for hiding this comment

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

Thanks for the PR!

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Razorr1996, 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 Jul 17, 2024
@spowelljr spowelljr merged commit 2eec0f8 into kubernetes:master Jul 17, 2024
25 of 37 checks passed
@Razorr1996 Razorr1996 deleted the Replace-replicationcontroller-with-deployment-in-addons branch July 17, 2024 23:28
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/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Registry addon uses ReplicationController instead of Deployment
6 participants