rndIndy opened a new issue #1232: Camel-K Doesn't Create a Service or Ingress 
for an Integration
URL: https://github.com/apache/camel-k/issues/1232
 
 
   I'm trying to use Camel-k with the CXF component to create a pass through 
proxy for a SOAP service running outside my K8S cluster and I am having trouble 
exposing the port to the outside world or to other pods in the cluster. I was 
able to generate a service and ingress following the RestWithUndertow example, 
but not with my integration. My code is in the picture below.
   
   <img width="724" alt="Camel-K CXF Code" 
src="https://user-images.githubusercontent.com/60113204/73306925-32958080-41eb-11ea-9332-1a8e6fdc3d57.PNG";>
   
   I am running the following command to create the integration:
   
   kamel run --name=cxf-test --trait service.enabled=true --trait 
container.service-port=8080 -d camel-cxf -d 
mvn:org.apache.cxf:cxf-rt-transports-http-jetty:3.3.5 cxfTest.java --dev
   
   I have tried with the traits above and the ingress traits to no avail. My 
integration yaml looks like the following.
   
   <img width="322" alt="Camel-k Integration yaml" 
src="https://user-images.githubusercontent.com/60113204/73307203-bea7a800-41eb-11ea-8333-d59963c1ce5b.PNG";>
   
   It shows a no http service is required message under type 
"DeploymentAvailable" and that no host or service is defined under 
"ServiceAvailable." I have verified that the integration works as a proxy by 
using the command kubectl exec -it <pod_name> -- /bin/bash to get inside the 
container and manually send a SOAP request to the proxy. I am unable to access 
the proxy from outside the container however. 
   
   I have used a work around in the meantime by manually creating my own 
service and applying it to the integration.
   
   <img width="187" alt="Camel-k Service" 
src="https://user-images.githubusercontent.com/60113204/73308277-e861ce80-41ed-11ea-81b7-838b2a1cc714.PNG";>
   
   Kubectl apply -f cxf-service.yaml 
   
   This seemingly fixes the problem and I am able to expose and access the port 
from outside the cluster. With this method I have been able to get the 
functionality I was looking for, but it is not ideal however, because the 
service needs to applied every time the integration code is updated.
    
   What would be the "proper" way to ensure that kamel run generates a service 
and an ignress?
   
   
    
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to