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: cloud init problems with ubuntu #1150

Merged
merged 10 commits into from
Aug 22, 2024
Merged

fix: cloud init problems with ubuntu #1150

merged 10 commits into from
Aug 22, 2024

Conversation

faiq
Copy link
Collaborator

@faiq faiq commented Aug 18, 2024

What problem does this PR solve?:

This pr attempts to solve:

https://jira.nutanix.com/browse/NCN-100790
https://jira.nutanix.com/browse/NCN-102002

by only using our copied datasource module on older versions of cloud-init. this aligns us a little closer to the upstream image-builder tasks

attempting to build these images but im unable to run kib locally with my credentials for vsphere

this is safe for the current version we are pinning in ubuntu -- 23.1.2 because it already contains DataSourceVmWare.py

Which issue(s) does this PR fix?:

Special notes for your reviewer:

Does this PR introduce a user-facing change?:


@github-actions github-actions bot added fix and removed fix labels Aug 18, 2024
@faiq faiq added the runs-vsphere-tests runs the vsphere e2e tests label Aug 19, 2024
@faiq
Copy link
Collaborator Author

faiq commented Aug 20, 2024

I dont think this is quite ready

this somehow pulled in an even older version of cloud init.

@faiq faiq force-pushed the faiq/fix-cloud-init-woes branch from 4a09d1f to 41a8c34 Compare August 20, 2024 18:09
@faiq
Copy link
Collaborator Author

faiq commented Aug 21, 2024

root@e2e-vsphere-air-gapped-test-1724250617-control-plane-6q2h8:/home/konvoy# crictl ps
CONTAINER           IMAGE               CREATED              STATE               NAME                      ATTEMPT             POD ID              POD
003b714215ceb       3af2ab51e1364       About a minute ago   Running             kube-apiserver            0                   733aa6dcf4429       kube-apiserver-e2e-vsphere-air-gapped-test-1724250617-control-plane-6q2h8
2610995525975       3861cfcd7c04c       About a minute ago   Running             etcd                      0                   a2e1573adb1f9       etcd-e2e-vsphere-air-gapped-test-1724250617-control-plane-6q2h8
32cfb42264efb       083b81fc09e85       About a minute ago   Running             kube-controller-manager   0                   f4e61bc2f8b05       kube-controller-manager-e2e-vsphere-air-gapped-test-1724250617-control-plane-6q2h8
ca9e900c8fb6d       49d9b8328a8fd       About a minute ago   Running             kube-scheduler            0                   3a7f747eb0957       kube-scheduler-e2e-vsphere-air-gapped-test-1724250617-control-plane-6q2h8
root@e2e-vsphere-air-gapped-test-1724250617-control-plane-6q2h8:/home/konvoy# cloud-init --version
/usr/bin/cloud-init 24.1.3-0ubuntu1~20.04.5

looks like this is working fine - added some extra commits to make it pull a newer cloud init.

@faiq faiq force-pushed the faiq/fix-cloud-init-woes branch from 41a8c34 to d4015f3 Compare August 21, 2024 14:40
@faiq faiq removed the do not merge label Aug 21, 2024
@faiq
Copy link
Collaborator Author

faiq commented Aug 21, 2024

for some reason i get v22.0 but that has datasource.py

https://github.com/canonical/cloud-init/blob/ubuntu/22.2-0ubuntu1_20.04.1/cloudinit/sources/DataSourceVMware.py

vsphere-clone.kib_image: TASK [providers : Set cloud-init version] **************************************
    vsphere-clone.kib_image: ok: [default]
    vsphere-clone.kib_image:
    vsphere-clone.kib_image: TASK [providers : Deprecation warning for disabling password authentication] ***
    vsphere-clone.kib_image: ok: [default] => {
    vsphere-clone.kib_image:     "msg": "22.2-0ubuntu1~20.04.3"
    vsphere-clone.kib_image: }
    vsphere-clone.kib_image:
    vsphere-clone.kib_image: TASK [providers : Install cloud-init packages] *********************************
    vsphere-clone.kib_image: skipping: [default]

i think this is happening because our base iso is old

@supershal
Copy link
Collaborator

added 9b114a7 to remove cloud-init dropin that configures cloud-init to use custom vmware guest datasource.

@supershal supershal changed the title fix: cloud init problems with ubuntu fix: cloud init problems with ubuntu Aug 21, 2024
@github-actions github-actions bot added fix and removed fix labels Aug 21, 2024
@supershal supershal force-pushed the faiq/fix-cloud-init-woes branch from 58cdf0e to fa99aa0 Compare August 21, 2024 22:15
@supershal
Copy link
Collaborator

supershal commented Aug 21, 2024

Created release template and running konvoy e2e tests.
RHEL 8.5 https://github.com/mesosphere/konvoy2/actions/runs/10498724952/job/29084248822 🟢
Ubuntu 2204: https://github.com/mesosphere/konvoy2/actions/runs/10498700886 🟢

@supershal supershal changed the title fix: cloud init problems with ubuntu fix: cloud init problems with ubuntu Aug 22, 2024
@github-actions github-actions bot added fix and removed fix labels Aug 22, 2024
@supershal supershal merged commit c35b7d4 into main Aug 22, 2024
25 checks passed
@supershal supershal deleted the faiq/fix-cloud-init-woes branch August 22, 2024 17:20
supershal added a commit that referenced this pull request Aug 24, 2024
* fix: install guest info if cloud init version is > 23.1.2

* ci: adds basic ubuntu test

* fix: adds handling for redhat system and cloud init

* !fixup: higher parallel

* fix: adds override for ubuntu tests

* do not merge: build basic os for ubuntu

* do not merge: ensure new cloud init for tests

* fix: remove package pining

* fix: remvove cloud-init dropin for custom vmware guest datasource

* fix: magefile configuration to create vsphere infa override file

---------

Co-authored-by: Shalin Patel <[email protected]>
supershal added a commit that referenced this pull request Aug 24, 2024
* fix: cloud init problems with ubuntu (#1150)

* fix: install guest info if cloud init version is > 23.1.2

* ci: adds basic ubuntu test

* fix: adds handling for redhat system and cloud init

* !fixup: higher parallel

* fix: adds override for ubuntu tests

* do not merge: build basic os for ubuntu

* do not merge: ensure new cloud init for tests

* fix: remove package pining

* fix: remvove cloud-init dropin for custom vmware guest datasource

* fix: magefile configuration to create vsphere infa override file

---------

Co-authored-by: Shalin Patel <[email protected]>

* ci: run rocky basic e2e tests

---------

Co-authored-by: Faiq <[email protected]>
@dlipovetsky dlipovetsky restored the faiq/fix-cloud-init-woes branch September 12, 2024 22:50
dlipovetsky added a commit that referenced this pull request Oct 9, 2024
* fix: cloud init problems with ubuntu (#1150)

* fix: install guest info if cloud init version is > 23.1.2

* ci: adds basic ubuntu test

* fix: adds handling for redhat system and cloud init

* !fixup: higher parallel

* fix: adds override for ubuntu tests

* do not merge: build basic os for ubuntu

* do not merge: ensure new cloud init for tests

* fix: remove package pining

* fix: remvove cloud-init dropin for custom vmware guest datasource

* fix: magefile configuration to create vsphere infa override file

---------

Co-authored-by: Shalin Patel <[email protected]>

* ci: run rocky basic e2e tests

---------

Co-authored-by: Faiq <[email protected]>
Signed-off-by: Daniel Lipovetsky <[email protected]>
dlipovetsky added a commit that referenced this pull request Oct 9, 2024
* fix: cloud init problems with ubuntu (#1150)

* fix: install guest info if cloud init version is > 23.1.2

* ci: adds basic ubuntu test

* fix: adds handling for redhat system and cloud init

* !fixup: higher parallel

* fix: adds override for ubuntu tests

* do not merge: build basic os for ubuntu

* do not merge: ensure new cloud init for tests

* fix: remove package pining

* fix: remvove cloud-init dropin for custom vmware guest datasource

* fix: magefile configuration to create vsphere infa override file

---------



* ci: run rocky basic e2e tests

---------

Signed-off-by: Daniel Lipovetsky <[email protected]>
Co-authored-by: Faiq <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix runs-vsphere-tests runs the vsphere e2e tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants