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

feat: Run UATs from a remote commit #67

Merged
merged 5 commits into from
Mar 29, 2024
Merged

Conversation

orfeas-k
Copy link
Contributor

This PR fixes #65. Implemented solution is described in #65 (comment). It essentially add the option of running tests either from:

  • a remote branch of charmed-kubeflow-uats repository.
  • the local copy of the repository.

Closes #65

Testing

In order to test this, one needs to:

  1. Deploy CKF in a microk8s environment and run tox -e kubeflow-local.
  2. Deploy CKF to an AKS/EKS cluster and run tox -e kubeflow-remote -- --branch kf-5473-add-remote-option.

That being said, I 've tested option 2 in an AKS cluster only (it works) and it will be tested also by the CI once it is implemented in canonical/bundle-kubeflow#850. It should work in EKS too but if it doesn't, we already have a different issue for EKS #55 and a task too canonical/bundle-kubeflow#802, thus if it doesn't work, it will be tackled as part of those efforts.

Add option to run tests either from:
* a remote branch of charmed-kubeflow-uats repository.
* the local copy of the repository
@kimwnasptd
Copy link
Contributor

@orfeas-k would it be possible to run a git command and detect the commit from which the test runs, and then use this to fetch from when running remotely?

Essentially to avoid having folks to define the branch/commit manually and have the driver code detect the commit and tell it to the remote code. But this is a high level comment, and maybe not feasible depending on how the code is executed in the remote.

Copy link
Contributor

@NohaIhab NohaIhab left a comment

Choose a reason for hiding this comment

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

thanks @orfeas-k , some small comments

driver/test_kubeflow_workloads.py Outdated Show resolved Hide resolved
tox.ini Show resolved Hide resolved
@orfeas-k orfeas-k force-pushed the kf-5473-add-remote-option branch from e5e2a7b to 71fc6d4 Compare March 29, 2024 08:37
Remove `branch` option and automatically grab currently checked out
commit and use that for remote. Details in #65
@orfeas-k orfeas-k force-pushed the kf-5473-add-remote-option branch from 71fc6d4 to 68482cd Compare March 29, 2024 08:40
@orfeas-k
Copy link
Contributor Author

orfeas-k commented Mar 29, 2024

@kimwnasptd Changed implementation to grab the checked out commit from the local repository and use this to sync the tests in the created volume. If the commit doesnt exist, tests will fail and log git-sync's initContainer logs. Added #65 (comment).

@kimwnasptd
Copy link
Contributor

@orfeas-k nice! The changes LGTM, so if/when @NohaIhab is also OK we can merge

tox.ini Outdated Show resolved Hide resolved
Copy link
Contributor

@NohaIhab NohaIhab left a comment

Choose a reason for hiding this comment

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

LGTM!

@orfeas-k orfeas-k changed the title feat: Run UATs from a remote branch feat: Run UATs from a remote commit Mar 29, 2024
@orfeas-k orfeas-k merged commit 4ca5f8e into main Mar 29, 2024
1 check passed
@orfeas-k orfeas-k deleted the kf-5473-add-remote-option branch March 29, 2024 10:56
orfeas-k added a commit to canonical/bundle-kubeflow that referenced this pull request Mar 29, 2024
Update UATs environment used in `full-bundle-tests.yaml` used after changes in canonical/charmed-kubeflow-uats#67.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

UATs cannot run in a remote node due to PVC hostpath
3 participants