Add openhab-cli and vim.tiny
Both were not part of the Docker images.
vim-tiny does only require 2 small additional dependencies on Debian, vim-nox is much larger. An additional symlink vim is added for convenience.
On Alpine, the package vim is much smaller and needs only two dependencies.
openhab-cli is directly downloaded from the linuxpkg repo. As that repo does not have version branches, this is just the current blob.
To make it work, environment variable OPENHAB_RUNTIME is needed as well.
@wborn WDYT about this one? Shall we add it?
I'm not so sure. You can edit files using your favorite editor installed on the host. Looks like there will be issues when using openhab-cli in containers as some commands don't work when openHAB is running. When using Docker you'd rather create backups of volumes anyhow. Resetting permissions is done on startup as well.
The feature I was missing is openhab-cli console.
I needed to query my knx plugin, which has a console extension.
Is there a simple way to get it with the docker image?
Vim - fair point, I can remove it. But it won't hurt. Just a few KB.
Is there a simple way to get it with the docker image?
If you want to get into the console from the host just use a script/alias that runs:
docker exec -it openhab /openhab/runtime/bin/client -p habopen
You can also configure the Karaf SSH server so you can use any SSH client to login to the console on the host or any machine.