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

✨ Add vcsim server provider #2613

Merged
merged 1 commit into from
Feb 1, 2024

Conversation

fabriziopandini
Copy link
Member

What this PR does / why we need it:
This PR adds a vcsim server that can be used in tilt for:

  • Testing CAPV in legacy mode, using vcsim instead of a real vCenter
  • Testing CAPV in supervisor mode, using vcsim instead of a real vCenter

The second option also provides some of the building blocks for implementing E2E for CAPV in supervisor mode on VMC (or on any vSphere), but some work is still necessary to make this possible

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jan 11, 2024
@fabriziopandini fabriziopandini marked this pull request as draft January 11, 2024 18:32
@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Jan 11, 2024
Copy link

codecov bot commented Jan 11, 2024

Codecov Report

Attention: 28 lines in your changes are missing coverage. Please review.

Comparison is base (b230286) 64.94% compared to head (8245cd0) 64.19%.
Report is 54 commits behind head on main.

Files Patch % Lines
pkg/util/supervisor.go 0.00% 17 Missing ⚠️
internal/test/helpers/vcsim/builder.go 15.38% 9 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2613      +/-   ##
==========================================
- Coverage   64.94%   64.19%   -0.75%     
==========================================
  Files         118      118              
  Lines        8580     8620      +40     
==========================================
- Hits         5572     5534      -38     
- Misses       2582     2647      +65     
- Partials      426      439      +13     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@fabriziopandini
Copy link
Member Author

/hold
It seems there is ongoing work in vcsim that could help us here, I'm gathering info

@k8s-ci-robot k8s-ci-robot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Jan 12, 2024
@sbueringer
Copy link
Member

@fabriziopandini IIRC you wanted to make some further changes before review, correct?

@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jan 25, 2024
@fabriziopandini fabriziopandini marked this pull request as ready for review January 25, 2024 15:41
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jan 25, 2024
@fabriziopandini
Copy link
Member Author

/hold cancel
the ongoing work in vcsim will make it easier some parts of the CAPV testing effort, but we still need this work if we want to keep the simulated environment as lightweight as possible (e.g. don't use a container for each VM)

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 25, 2024
@fabriziopandini
Copy link
Member Author

@sbueringer this one should be ready for review now

@sbueringer
Copy link
Member

/retest

@sbueringer
Copy link
Member

/test pull-cluster-api-provider-vsphere-e2e-main

(to run all tests)

@sbueringer sbueringer mentioned this pull request Jan 29, 2024
7 tasks
Copy link
Member

@sbueringer sbueringer left a comment

Choose a reason for hiding this comment

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

I changed my mind and added comments instead of opening a PR (A large percentag of my points are questions)

tilt-provider.json Show resolved Hide resolved
test/framework/vmoperator/vmoperator.go Outdated Show resolved Hide resolved
test/framework/vmoperator/vmoperator.go Show resolved Hide resolved
test/framework/vmoperator/vmoperator.go Outdated Show resolved Hide resolved
test/framework/vmoperator/vmoperator.go Outdated Show resolved Hide resolved
test/infrastructure/vcsim/controllers/vmip.go Outdated Show resolved Hide resolved
test/infrastructure/vcsim/controllers/vmip.go Outdated Show resolved Hide resolved
test/infrastructure/vcsim/controllers/vmbootstrap.go Outdated Show resolved Hide resolved
test/infrastructure/vcsim/controllers/vmbootstrap.go Outdated Show resolved Hide resolved
test/infrastructure/vcsim/controllers/vmbootstrap.go Outdated Show resolved Hide resolved
@sbueringer
Copy link
Member

/retest

tilt-provider.json Outdated Show resolved Hide resolved
test/infrastructure/vcsim/main.go Show resolved Hide resolved
test/framework/vmoperator/vmoperator.go Outdated Show resolved Hide resolved
test/framework/vmoperator/vmoperator.go Show resolved Hide resolved
test/infrastructure/vcsim/main.go Outdated Show resolved Hide resolved
@sbueringer
Copy link
Member

Last one from my side

@sbueringer
Copy link
Member

Thank you very much.

Really nice work :)

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 1, 2024
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 384539b0d244b9575d0abb922aacac95a290d605

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: sbueringer

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 Feb 1, 2024
@k8s-ci-robot k8s-ci-robot merged commit 298c373 into kubernetes-sigs:main Feb 1, 2024
19 checks passed
@k8s-ci-robot k8s-ci-robot added this to the v1.10 milestone Feb 1, 2024
@fabriziopandini fabriziopandini deleted the vcsim-server branch February 24, 2024 13:37
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. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants