Page MenuHomePhabricator

Investigate new Magnum drivers
Closed, ResolvedPublic

Description

Magnum release notes say:

Deprecate the use of ‘heat’ driver in favor of modern Kubernetes Cluster API based drivers: ‘k8s_capi_helm’ [1] or ‘k8s_cluster_api’ [2]. User still using ‘heat’ driver are encouraged to migrate to one of the abovementioned as ‘heat’ driver will be removed in the future.

The heat driver is not great, but the capi drivers require some pretty complex setup.

Details

Related Changes in Gerrit:
SubjectAuthorRepoBranchLines +/-
Andrew Bogottoperations/puppetproduction+1 -1
Andrew Bogottoperations/puppetproduction+0 -11
Andrew Bogottoperations/puppetproduction+1 -1
Andrew Bogottoperations/puppetproduction+27 -46
Andrew Bogottoperations/puppetproduction+3 -1
Andrew Bogottoperations/puppetproduction+7 -2
Andrew Bogottoperations/puppetproduction+1 -1
Andrew Bogottoperations/puppetproduction+6 -16
Andrew Bogottoperations/puppetproduction+13 -0
Andrew Bogottoperations/puppetproduction+35 -37
Andrew Bogottoperations/puppetproduction+1 -1
Andrew Bogottoperations/puppetproduction+51 -23
Andrew Bogottoperations/puppetproduction+132 -0
Andrew Bogottoperations/puppetproduction+65 -0
Andrew Bogottoperations/puppetproduction+24 -0
Andrew Bogottoperations/puppetproduction+3 -0
Andrew Bogottoperations/puppetproduction+5 -0
Andrew Bogottoperations/puppetproduction+10 -32
Andrew Bogottoperations/puppetproduction+43 -1
Andrew Bogottlabs/privatemaster+24 -0
Andrew Bogottoperations/puppetproduction+23 -0
Show related patches Customize query in gerrit
Related Changes in GitLab:
TitleReferenceAuthorSource BranchDest Branch
Add 'magnum' service project in and default templates in codfw1devrepos/cloud/cloud-vps/tofu-infra!328andrewtemplatesmain
Add 'magnum' service project and default templates in codfw1devrepos/cloud/cloud-vps/tofu-infra!325andrewmagnumtemplatesmain
Add 'magnum' service project and a couple default templates in codfw1devrepos/cloud/cloud-vps/tofu-infra!324andrewmagnummain
magnum: add cluster-api-based coe cluster.repos/cloud/cloud-vps/tf-infra-test!8andrewmagnum-cluster-apimain
Add 'magnum' service project in codfw1devrepos/cloud/cloud-vps/tofu-infra!248andrewmagnummain
Manage default security group in Octaviarepos/cloud/cloud-vps/tofu-infra!245andrewoctaviasecgroupsmain
Customize query in GitLab

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes

Change #1175557 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[labs/private@master] Added dump capiservicek3s.yaml file

https://gerrit.wikimedia.org/r/1175557

Change #1175557 merged by Andrew Bogott:

[labs/private@master] Added dummy capiservicek3s.yaml file

https://gerrit.wikimedia.org/r/1175557

Change #1175555 merged by Andrew Bogott:

[operations/puppet@production] Magnum: use capi-helm driver in codfw1dev

https://gerrit.wikimedia.org/r/1175555

Change #1175579 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Magnum: only include [heat_client] if heat is enabled

https://gerrit.wikimedia.org/r/1175579

Change #1175579 merged by Andrew Bogott:

[operations/puppet@production] Magnum: only include [heat_client] if heat is enabled

https://gerrit.wikimedia.org/r/1175579

Change #1175590 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Magnum: install python3-magnum-capi-helm when needed

https://gerrit.wikimedia.org/r/1175590

Change #1175590 merged by Andrew Bogott:

[operations/puppet@production] Magnum: install python3-magnum-capi-helm when needed

https://gerrit.wikimedia.org/r/1175590

Change #1175598 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Magnum: install helm when needed

https://gerrit.wikimedia.org/r/1175598

Change #1175598 merged by Andrew Bogott:

[operations/puppet@production] Magnum: install helm when needed

https://gerrit.wikimedia.org/r/1175598

Change #1175625 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Add k3s class for installing k3s on a single cloud-vps node

https://gerrit.wikimedia.org/r/1175625

Change #1175626 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Add puppet class and profile to create k3s cluster-api worker for Magnum

https://gerrit.wikimedia.org/r/1175626

Change #1175932 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Trivial profile for a cloud-vps-hosted chartmuseum instance

https://gerrit.wikimedia.org/r/1175932

Change #1175932 merged by Andrew Bogott:

[operations/puppet@production] Trivial profile for a cloud-vps-hosted chartmuseum instance

https://gerrit.wikimedia.org/r/1175932

Change #1176513 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Magnum/capi: switch to using wmf-internal image and helm repos

https://gerrit.wikimedia.org/r/1176513

Change #1175625 merged by Andrew Bogott:

[operations/puppet@production] Add k3s class for installing k3s on a single cloud-vps node

https://gerrit.wikimedia.org/r/1175625

Change #1175626 merged by Andrew Bogott:

[operations/puppet@production] Add puppet class and profile to create k3s cluster-api worker for Magnum

https://gerrit.wikimedia.org/r/1175626

Change #1176513 merged by Andrew Bogott:

[operations/puppet@production] Magnum/capi: switch to using wmf-internal image and helm repos

https://gerrit.wikimedia.org/r/1176513

Change #1179278 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum capi_helm: use the cloudinfra chartmuseum repo for helm charts

https://gerrit.wikimedia.org/r/1179278

Change #1179278 merged by Andrew Bogott:

[operations/puppet@production] magnum capi_helm: use the cloudinfra chartmuseum repo for helm charts

https://gerrit.wikimedia.org/r/1179278

The status of this is:

  • The new drivers are running in codfw1dev and seem to be working.
  • Migrating to the new drivers in eqiad1 will require some template adjustments for users, which requires associated communication and coordination
  • Migrating to the new drivers in eqiad1 is also blocked on completion of the Flamingo upgrade T406516 which is delayed because of a pretty big surprise issue that showed up in codfw1dev and has me wanting to sit back and wait for the next shoe to drop

I am definitely the bottleneck on this task, but I just got back from vacation, am somewhat sick, and am surrounded by social rot and collapse (I live in Minnesota) so it'll be a bit before I can turn my full attention here.

...and, it turns out upstream has better support for the capi driver (not the capi-helm driver) so now I'm setting that up instead. https://stackhpc-kayobe-config.readthedocs.io/en/stackhpc-2025.1/configuration/magnum-capi.html

Change #1276821 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Magnum: switch codfw1dev from capi-helm to magnum-cluster-api driver

https://gerrit.wikimedia.org/r/1276821

Change #1276821 merged by Andrew Bogott:

[operations/puppet@production] Magnum: switch codfw1dev from capi-helm to magnum-cluster-api driver

https://gerrit.wikimedia.org/r/1276821

Change #1276844 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum cluster-api: include k8s config file on codfw1dev

https://gerrit.wikimedia.org/r/1276844

Change #1276844 merged by Andrew Bogott:

[operations/puppet@production] magnum cluster-api: include k8s config file on codfw1dev

https://gerrit.wikimedia.org/r/1276844

Change #1283047 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum: complete rename from capihelm to clusterapi

https://gerrit.wikimedia.org/r/1283047

Change #1283051 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum: container-api to version 1.12.7 -- the 1.13.x doesn't work with capo

https://gerrit.wikimedia.org/r/1283051

Change #1283047 merged by Andrew Bogott:

[operations/puppet@production] magnum: complete rename from capihelm to clusterapi

https://gerrit.wikimedia.org/r/1283047

Change #1283051 merged by Andrew Bogott:

[operations/puppet@production] magnum: container-api to version 1.12.7 -- the 1.13.x doesn't work with capo

https://gerrit.wikimedia.org/r/1283051

Change #1283079 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum-container-api: Install ORC CRD before setting up clusterctl

https://gerrit.wikimedia.org/r/1283079

Change #1283079 merged by Andrew Bogott:

[operations/puppet@production] magnum-container-api: Install ORC CRD before setting up clusterctl

https://gerrit.wikimedia.org/r/1283079

Change #1283834 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum.conf: set nova-api compatibility to v2.15

https://gerrit.wikimedia.org/r/1283834

Change #1283834 merged by Andrew Bogott:

[operations/puppet@production] magnum.conf: set nova-api compatibility to v2.15

https://gerrit.wikimedia.org/r/1283834

Change #1288858 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Magnum: refactor to allow both magnum-cluster-api and heat driver

https://gerrit.wikimedia.org/r/1288858

Change #1288858 merged by Andrew Bogott:

[operations/puppet@production] Magnum: refactor to allow both magnum-cluster-api and heat driver

https://gerrit.wikimedia.org/r/1288858

Change #1288904 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] Magnum: re-enable heat driver in codfw1dev

https://gerrit.wikimedia.org/r/1288904

"The new CAPI driver and the old Heat driver are compatible and can both be active on the same deployment, and the decision of which driver is used for a given template depends on certain parameters inferred from the Magnum cluster template. For the new driver, these parameters are {'server_type': 'vm', 'os': 'ubuntu', 'coe': kubernetes'}. Drivers can be enabled and disabled using the disabled_drivers parameter in the [drivers] section of magnum.conf."

Change #1288904 merged by Andrew Bogott:

[operations/puppet@production] Magnum: re-enable heat driver in codfw1dev

https://gerrit.wikimedia.org/r/1288904

"The new CAPI driver and the old Heat driver are compatible and can both be active on the same deployment"

That should make testing and switching mush easier. Yay upstream! :)

That should make testing and switching mush easier. Yay upstream! :)

Yeah! I just flip-flopped between the two drivers in codfw1dev a few times and it worked fine. The switch is a big opaque/accidental: basically if you tell magnum to make a cluster of ubuntu workers it uses the new driver vs. fedora workers it uses heat. I'll document once I have a better grip on this.

Time for a new update:

Things are back to pretty much working in codfw1dev. The only serious blocker to deployment in eqiad1 is the issue with docker_volume_size[0] which upstream seems to have a fix in process for. So, next steps are:

  • wait a bit for upstream to resolve the docker_volume_size thing
  • redeploy in codfw1dev and make sure there aren't major regressions
  • (meanwhile...) resolve packaging blockers so that we can get a magnum-cluster-api package on apt.wikimedia.org
  • build a capi worker node in eqiad1 based on latest versions/puppet
  • switch on the new driver in eqiad1
  • test a bit
  • find early adopters and/or test with PAWs

[0] https://github.com/vexxhost/magnum-cluster-api/issues/1028

Change #1295472 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum: remove refs to helm chart repo

https://gerrit.wikimedia.org/r/1295472

Change #1295472 merged by Andrew Bogott:

[operations/puppet@production] magnum: remove refs to helm chart repo

https://gerrit.wikimedia.org/r/1295472

  • wait a bit for upstream to resolve the docker_volume_size thing added this as patch to our debian package instead
  • redeploy in codfw1dev and make sure there aren't major regressions
  • (meanwhile...) resolve packaging blockers so that we can get a magnum-cluster-api package on apt.wikimedia.org
  • build a capi worker node in eqiad1 based on latest versions/puppet
  • switch on the new driver in eqiad1
  • test a bit
  • find early adopters and/or test with PAWs

Change #1295473 had a related patch set uploaded (by Andrew Bogott; author: Andrew Bogott):

[operations/puppet@production] magnum: enable magnum-cluster-api driver in eqiad1

https://gerrit.wikimedia.org/r/1295473

Change #1295473 merged by Andrew Bogott:

[operations/puppet@production] magnum: enable magnum-cluster-api driver in eqiad1

https://gerrit.wikimedia.org/r/1295473

This has run into a new blocker, logged upstream as https://github.com/vexxhost/magnum-cluster-api/issues/1057

We can proceed and just rely on ubuntu worker nodes but it sure would be nice to use debian instead. I'm going to give upstream a few days to respond before giving up my debian hopes.

andrew closed https://gitlab.wikimedia.org/repos/cloud/cloud-vps/tofu-infra/-/merge_requests/324

Add 'magnum' service project and a couple default templates in codfw1dev

The new driver is up and running and in use for >0 real world clusters.