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

Allow prioritize user-addons / helm-releases #3201

Open
kron4eg opened this issue May 21, 2024 · 3 comments
Open

Allow prioritize user-addons / helm-releases #3201

kron4eg opened this issue May 21, 2024 · 3 comments
Labels
kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API kind/feature Categorizes issue or PR as related to a new feature. priority/high sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management.
Milestone

Comments

@kron4eg
Copy link
Member

kron4eg commented May 21, 2024

Description of the feature you would like to add / User story

Currently we have useraddons deployed before the helm releases. But in case when CNI is set to be external and the actual CNI driver is deployed via the helmRelease, nodes will not be Ready until helm release happened.

If we simply change the order, the vise-versa problem will be true in case when CNI driver is deployed via the addon.

Solution details

Unify the logic to deploy useraddons and helm releases. Add weight fields to both Addon and HelmRelease types. Consider this field as a priority when deploying.

Alternative approaches

Add new type in KubeOneCluster workloads that will unify under one umbrella all existing and future types of deploys (addons/helmReleases). Deprecate addons.addons and helmReleases.

examples:

addons:
  enable: true
  addons: ## this will be deprecated, yet still working for some time
  - name: default-storage-class
    weight: 100

helmReleases:  ## this will be deprecated, yet still working for some time
  - chart: kured
    repoURL: https://kubereboot.github.io/charts
    namespace: kube-system
    version: 5.4.5
    weight: 500

## this will make a unified list naturally defining the order of deployment
workloads:
  - addon:
      name: backups-restic
  - addon:
      name: unattended-upgrades
  - helmChart:
      chart: kured
      repoURL: https://kubereboot.github.io/charts
      namespace: kube-system
      version: 5.4.5
  - addon:
      name: default-storage-class
@kron4eg kron4eg added kind/feature Categorizes issue or PR as related to a new feature. sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management. labels May 21, 2024
@kron4eg kron4eg added this to the KubeOne 1.9 milestone May 21, 2024
@kron4eg kron4eg mentioned this issue May 21, 2024
@xmudrii xmudrii added kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API priority/high labels Jun 24, 2024
@kron4eg
Copy link
Member Author

kron4eg commented Sep 2, 2024

Closed in #3248

@kron4eg kron4eg closed this as completed Sep 2, 2024
@xmudrii
Copy link
Member

xmudrii commented Jan 6, 2025

I don't think that we ever fixed this issue because looking at

kubeone/pkg/tasks/tasks.go

Lines 279 to 293 in 8b8d794

{
Fn: addons.Ensure,
Operation: "applying addons",
Description: "ensure embedded addons",
},
{
Fn: addons.EnsureUserAddons,
Operation: "applying addons",
Description: "ensure custom addons",
Predicate: func(s *state.State) bool { return s.Cluster.Addons != nil },
},
{
Fn: localhelm.Deploy,
Operation: "releasing core helm charts",
},

it still looks like we always first deploy addons, so you can't deploy any Helm chart before the addons.

If I'm mistaken, @kron4eg can you please provide an example of how this works in the new API version?
/reopen

@kubermatic-bot kubermatic-bot reopened this Jan 6, 2025
@kubermatic-bot
Copy link
Contributor

@xmudrii: Reopened this issue.

In response to this:

I don't think that we ever fixed this issue because looking at

kubeone/pkg/tasks/tasks.go

Lines 279 to 293 in 8b8d794

{
Fn: addons.Ensure,
Operation: "applying addons",
Description: "ensure embedded addons",
},
{
Fn: addons.EnsureUserAddons,
Operation: "applying addons",
Description: "ensure custom addons",
Predicate: func(s *state.State) bool { return s.Cluster.Addons != nil },
},
{
Fn: localhelm.Deploy,
Operation: "releasing core helm charts",
},
, it still looks like we always first deploy addons, so you can't deploy any Helm chart before the addons.

If I'm mistaken, @kron4eg can you please provide an example of how this works in the new API version?
/reopen

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API kind/feature Categorizes issue or PR as related to a new feature. priority/high sig/cluster-management Denotes a PR or issue as being assigned to SIG Cluster Management.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants