camel-k icon indicating copy to clipboard operation
camel-k copied to clipboard

`kamel operator` does not work locally

Open squakez opened this issue 3 years ago • 6 comments

The local camel k operator debugging procedure is not working any longer. The operator starts correctly but it is not able to run any Integration. I've tried setting KAMEL_OPERATOR_ID env variable but no luck.

I think it relates the changes introduced in https://github.com/apache/camel-k/pull/3358.

squakez avatar Jul 21 '22 10:07 squakez

@christophd do you mind having a look? is there any quick workaround?

squakez avatar Jul 21 '22 10:07 squakez

yes I have a look. What happens if you run the integration? is it being reconciled by the operator? also do you have a WATCH_NAMESPACE env set for the local operator? do you have any other global operator running on that environment?

christophd avatar Jul 21 '22 10:07 christophd

I've set the WATCH_NAMESPACE. The integration complains that an IntegrationPlatform is not found (even if I had to create on that namespace to override the registry setting).

squakez avatar Jul 21 '22 11:07 squakez

I managed to see that the problem is that the local operator does not understand the camel.apache.org/operator.id: camel-k annotation. If I remove it from both IntegrationPlatform and Integration they are reconciled correctly. We must understand how to make the local running operator to reconcile based on the annotation, as, for development purposes, having the local operator is really a must.

squakez avatar Aug 11 '22 08:08 squakez

I had another try with clean environment, and, if we set the KAMEL_OPERATOR_ID with the name of the operator, then, the resources are reconciled. I'll update the documentation accordingly.

squakez avatar Aug 11 '22 08:08 squakez

@squakez yes, I have started some investigation but got distracted by other stuff.

I also wanted to ask: In your scenario do you have another traditional operator running on the cluster? or is it only the local operator?

christophd avatar Aug 11 '22 08:08 christophd