mss55 opened a new issue, #6038:
URL: https://github.com/apache/camel-k/issues/6038

   ### What happened?
   
   Integration created with JIB strategy can't be running with non-root 
privilege.
   
   Pod crashed with log:
   ```
   Error: Could not find or load main class 
io.quarkus.bootstrap.runner.QuarkusEntryPoint
   Caused by: java.lang.ClassNotFoundException: 
io.quarkus.bootstrap.runner.QuarkusEntryPoint
   ```
   
   I created container with kit image manually `docker run --rm -it --user 
1001:1001 --entrypoint bash camel-k-kit-cu4h8ob6evos739qojvg:395852198`
   , run bash and inspect files permission:  
   ```
   I have no name!@60e635e71a4f:/$ id
   uid=1001 gid=1001 groups=1001
   
   I have no name!@60e635e71a4f:/$ ls -ld /deployments/
   drwxr-xr-x 3 root root 4096 Jan  1  1970 /deployments/
   
   I have no name!@60e635e71a4f:/$ ls -ld /deployments/dependencies/
   dr-xr--r-- 5 root root 4096 Jan  1  1970 /deployments/dependencies/
   
   I have no name!@60e635e71a4f:/$ ls -ld /deployments/dependencies/*
   ls: cannot access '/deployments/dependencies/app': Permission denied
   ls: cannot access '/deployments/dependencies/lib': Permission denied
   ls: cannot access '/deployments/dependencies/quarkus': Permission denied
   ls: cannot access '/deployments/dependencies/quarkus-app-dependencies.txt': 
Permission denied
   ls: cannot access '/deployments/dependencies/quarkus-run.jar': Permission 
denied
   ```
   
   Directory `/deployments/dependencies/` doesn't  have X (list) permission for 
other users and jar files inside can't be accessed. 
   
   Integration kit created with Spectrum publish strategy starts normally.
   
   ### Steps to reproduce
   
   1. Install IntegrationPlatform with Publish Strategy: Jib
   2. Run any integration as non-root user `kamel run hello.groovy --trait 
security-context.run-as-user=1001`
   3. Inspect integration pod logs
   
   ### Relevant log output
   
   ```shell
   Error: Could not find or load main class 
io.quarkus.bootstrap.runner.QuarkusEntryPoint
   Caused by: java.lang.ClassNotFoundException: 
io.quarkus.bootstrap.runner.QuarkusEntryPoint
   ```
   
   ### Camel K version
   
   2.5.0


-- 
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.

To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to