<p>I am doing a POC around the kubernetes Go Operator to perform some asynchronous actions in an application, and I expect to get a callback from a python application into the Operator, which can then go ahead to update the resource metadata, such as make changes to the Resource status fields.</p>
<p>I know that the controller used by the Kubernetes Go Operator SDK uses an API Server running on a specific port. But can that be used as a custom API server where I can set up paths for the webhook to work on?</p>
<p>Example of an expected callback API:</p>
<pre><code>curl -XPOST http://cyber-operator.svc/application/updateClusterState
</code></pre>
<p>I expect to run a procedure inside the operator when this API is called.</p>
<p>I searched the documentation and could not find something relevant. Can I run a separate API Server in the Operator? I am fine if it has to listen to a different port than the in-built controller.</p>

<p>operator-sdk doesn't start server, usually it list-watch k8s resources and reconcile, unless you add validating/mutating webhook explicitly (<a href="https://github.com/operator-framework/operator-sdk/blob/7e029625dde8f0d4cb88ac914af4deb7f5f85c4a/website/content/en/docs/building-operators/golang/webhooks.md" rel="nofollow noreferrer">https://github.com/operator-framework/operator-sdk/blob/7e029625dde8f0d4cb88ac914af4deb7f5f85c4a/website/content/en/docs/building-operators/golang/webhooks.md</a>)</p>
<p>Even it's possible, I suggest don't do this, just create a new http server on a new port.</p>
