Is it possible to make karaf run a set of command line commands?

2018-03-01 Thread Steinar Bang
Is it possible to make a karaf installation run a set of console commands? What I would like to do, is to try to create a dockerfile setting up a docker image for my webapp: https://github.com/steinarb/ukelonn And the steps listed in 6. and 8. below are run from the karaf console. Is it po

Re: Is it possible to make karaf run a set of command line commands?

2018-03-01 Thread Francois Papon
Hi Steinar, May be you can run Karaf console commands using the ssh client in the docker compose ? (I did not try this before and I'm interesting to know if it work's ;) François Le 02/03/2018 à 01:10, Steinar Bang a écrit : > Is it possible to make a karaf installation run a set of console > c

Re: Is it possible to make karaf run a set of command line commands?

2018-03-01 Thread Jean-Baptiste Onofré
Hi, you can change in etc/shell.init.script. Here you can define a set of commands executed at startup. You can also create a script wrapping all your commands. Regards JB On 03/01/2018 10:10 PM, Steinar Bang wrote: > Is it possible to make a karaf installation run a set of console > commands?

Re: Is it possible to make karaf run a set of command line commands?

2018-03-02 Thread Steinar Bang
> Francois Papon : > May be you can run Karaf console commands using the ssh client in the > docker compose ? (I did not try this before and I'm interesting to know > if it work's ;) With the help off sshpass, this works for simple one-liners, like "feature:install ukelonn". First install ss

Re: Is it possible to make karaf run a set of command line commands?

2018-03-02 Thread Francois Papon
Ok, thanks for your feeback ;) François Le 02/03/2018 à 20:57, Steinar Bang a écrit : >> Francois Papon : >> May be you can run Karaf console commands using the ssh client in the >> docker compose ? (I did not try this before and I'm interesting to know >> if it work's ;) > With the help off

Re: Is it possible to make karaf run a set of command line commands?

2018-03-17 Thread Michal Hlavac
you can use docker exec or compose exec to run multiple commands from file. create configure.cmd file with commands e.g. config:edit com.example.config config:property-set example.property value config:update then run: docker-compose exec -T container /opt/karaf/bin/client -b < configure.cmd m.

Re: Is it possible to make karaf run a set of command line commands?

2018-04-23 Thread Mike Hummel
I managed the problem starting karaf in the background and installing features via client after startup. Therefore you need to wait until karaf starts and installed default packages. You can see a sample here https://github.com/mhus/cherry-reactive/tree/master/reactive-docker/reactive-playgroun

Re: Is it possible to make karaf run a set of command line commands?

2018-04-23 Thread Jean-Baptiste Onofré
By the way to know when Karaf is fully started you have the Bootstrap service. It's what we use for the startup progress bar (like in ServiceMix). Regards JB Le 23 avr. 2018 à 11:17, à 11:17, Mike Hummel a écrit: >I managed the problem starting karaf in the background and installing >features v

Creating docker image from docker hub karaf image (Was: Is it possible to make karaf run a set of command line commands?)

2020-04-12 Thread Steinar Bang
> Jean-Baptiste Onofré : > Hi, > you can change in etc/shell.init.script. > Here you can define a set of commands executed at startup. You can also > create a > script wrapping all your commands. Tried this approach and I had some success. The "success" is in that I managed to end up with