I was trying to get SonarQube test instance for my HomeLab, and found out Bitnami docker image (link). I thought about using my RancherOS freshly updated VM for trying to run it.
The first obstacle happened to be the curl
. There is no curl installed on bare RancherOS instance. But there is wget
so a simple fix to replace those commands.
The second problem was bigger, you get docker-compose.yml
file, and have to run docker-compose to start the stack. But there is no docker-compose on RancherOS...
After searching the web I discovered there is a docker image with docker compose, but no instructions on how to execute it from container.
After some googling I crafted a woring command:
docker run --rm -it -v ${PWD}:/tmp -v /var/run/docker.sock:/var/run/docker.sock -w /tmp docker/compose up
mounts the current directory as-v ${PWD}:/tmp
/tmp
on docker container-v /var/run/docker.sock:/var/run/docker.sock
allows docker-compose to talk to rancherOS docker-w /tmp
sets the working directory for docker containerdocker/compose
is the latest compose imageup
is the command
Overall it's the equivalent of running docker-compose up
but without having docker-compose installed/available.