You can take a look on the script provided with Karaf:

https://github.com/apache/karaf/tree/master/assemblies/docker 
<https://github.com/apache/karaf/tree/master/assemblies/docker>

Regards
JB

> Le 8 avr. 2020 à 12:22, Steinar Bang <[email protected]> a écrit :
> 
>>>>>> Steinar Bang <[email protected]>:
> 
>>> Yep. AFAIK the docker:provision puts all karaf directories on the host VM. 
>>> That's the reason why we're doing it manually. Am I right with this?
> 
>> I googled the error message I got: docker: Error response from daemon: No 
>> command specified.
> 
>> I found this:
>> https://serverfault.com/questions/757210/no-command-specified-from-re-imported-docker-image-container
> 
>> Is the cause of my error message that docker:provision created an image
>> without e.g. the etc directory and expected the docker container to
>> provide those directories?
> 
> At a little further googling I tried adding a command to the run, to
> fire up karaf, but both my guesses ("bin/karaf" and "karaf"), failed:
> 
> [node1] (local) [email protected] ~
> $ docker run -p 8101:8101 -p 8181:8181 steinarb/ukelonn-demo:202004071205 
> bin/karaf
> docker: Error response from daemon: OCI runtime create failed: 
> container_linux.go:346: starting container process caused "exec: 
> \"bin/karaf\": stat bin/karaf: no such file or directory": unknown.
> ERRO[0001] error waiting for container: context canceled 
> [node1] (local) [email protected] ~
> $ docker run -p 8101:8101 -p 8181:8181 steinarb/ukelonn-demo:202004071205 
> karaf
> docker: Error response from daemon: OCI runtime create failed: 
> container_linux.go:346: starting container process caused "exec: \"karaf\": 
> executable file not found in $PATH": unknown.
> ERRO[0001] error waiting for container: context canceled 
> [node1] (local) [email protected] ~
> $ 
> 

Reply via email to