-
-
Notifications
You must be signed in to change notification settings - Fork 67
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
[docs]: How does remote development work now? #742
Comments
If i'm correct, the RegisterComponents was doing assembly scanning to find all the required components. Now you can register all components explicitly: services.AddKubernetesOperator()
.AddController<MyController, MyControlledResource>()
.AddFinalizer<MyFinalizer, MyControlledResource>("my-finalizer-identifier"); |
Hey @ian-buse If you do not use source generators ( You can see the code that is generated in the test files (https://github.com/buehler/dotnet-operator-sdk/tree/main/test/KubeOps.Generator.Test). The webhook install command and other commands regarding webhooks are no longer required. When creating the kustomize configs with the kubeops.cli, the cli detects if you have webhooks installed. If you do, it creates a self signed certificate (now without the help of the external tool) and the required resources. |
@ian-buse as an addition to your question in #740: Which currently includes:
There is nothing more "needed" by this time. If any of these commands are missing, the implmementation of this console thingy has a bug. |
No, the help is talking about much more than just these, which might confuse people :) |
I see now how this works now, thank you. I've opted not to use RegisterComponents() and do the registration manually. This still leaves a small problem with the documentation because it talks about a few commands that don't exist anymore. I'd be happy to remove the old commands from the documentation if you're okay with that. |
Quick fix for #742. Related to #756. That PR has added documentation for development webhooks. Co-authored-by: Christoph Bühler <[email protected]>
Describe the missing piece of documentation
Prior to v 8.x, there was good documentation on how to get your operator up and running, how to create and install webhooks, etc. Running the
install
and thenwebhooks install
commands worked well. I skipped upgrading to 8.x, and move straight to 9.0.0.With 9.0.0, there seems to be missing or out of date documentation for developing the operator, especially in regard to webhooks. The webhook commands are missing, and the CLI documentation references commands that as far as I can tell no longer exist.
In a somewhat related problem, the webhook example
Program.cs
seems to reference aRegisterComponents()
method that no longer exists, with the error'IOperatorBuilder' does not contain a definition for 'RegisterComponents' and no accessible extension method 'RegisterComponents' accepting a first argument of type 'IOperatorBuilder' could be found (are you missing a using directive or an assembly reference?)
Part of these issues were brought up in #740, but I wanted to make sure this gets seen. I have so far been unable to get my operator with webhooks working.
As a side note, I'd be happy to help contribute to documentation when I get things working again, if needed.
The text was updated successfully, but these errors were encountered: