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

Dry Run feature for k8s #1138

Closed
CodeWithEmad opened this issue Oct 12, 2024 · 7 comments
Closed

Dry Run feature for k8s #1138

CodeWithEmad opened this issue Oct 12, 2024 · 7 comments

Comments

@CodeWithEmad
Copy link
Member

The proposed dry run command for tutor would significantly enhance the deployment process by allowing users to preview the changes to the Open edX configuration before actually applying them to the Kubernetes cluster. This would help identify potential issues and avoid unintended disruptions in the live environment, ensuring a smoother deployment experience.
A subcommand of k8s, like :

tutor k8s dry  # I'm not sure about the naming

If there are no objections, I'll be happy to implement this.

@DawoudSheraz
Copy link
Contributor

@CodeWithEmad Hi. Can you give some examples and context on what this would achieve or help with? Thanks

@CodeWithEmad
Copy link
Member Author

CodeWithEmad commented Oct 14, 2024

Hey @DawoudSheraz. It can:

  • Preview configuration changes before applying them.
  • Identify potential conflicts or errors in advance.
  • Reduce the risk of unexpected issues in the live environment.
  • Save time by catching problems early in the deployment process.

This feature would be especially valuable for complex setups or when making significant changes to the Open edX configuration.

@DawoudSheraz
Copy link
Contributor

Hey @DawoudSheraz. It can:

  • Preview configuration changes before applying them.
  • Identify potential conflicts or errors in advance.
  • Reduce the risk of unexpected issues in the live environment.
  • Save time by catching problems early in the deployment process.

This feature would be especially valuable for complex setups or when making significant changes to the Open edX configuration.

Right. Will it be a wrapper to k8s dry run commands? Anyway, I get the potential use cases for this. Thanks for suggesting this.
@regisb What are your thoughts?

@CodeWithEmad
Copy link
Member Author

Will it be a wrapper to k8s dry run commands?

Yes, it will be a wrapper around kubectl apply --dry-run.

@regisb
Copy link
Contributor

regisb commented Oct 18, 2024

You mean, like make test-k8s or tutor k8s apply --dry-run=client --validate=true? Tutor already provides an API for kubectl apply. Maybe all we need is better documentation on this feature?

@DawoudSheraz
Copy link
Contributor

You mean, like make test-k8s or tutor k8s apply --dry-run=client --validate=true? Tutor already provides an API for kubectl apply. Maybe all we need is better documentation on this feature?

Ah, nice. make test-* inherently implies we are running some sort of tests (at least in Open edX ecosystem). I agree that documenting it differently can make it more visible.

@CodeWithEmad
Copy link
Member Author

And now I feel dumb :D
I didn't know about the tutor k8s apply command. I'll close this one and will come up with some changes in the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

3 participants