I need to run the following commands in the docker-compose file:
- '/var/run/docker.sock:/var/run/docker.sock'
- '$(which docker):$(which docker)'
I found a solution for this format:
- ${DOCKER_PATH}:/usr/bin/docker:ro
But in my case, I need to run this format $ (..): $ (..),
Is there any simple solution from docker-compose that it solves the problem?
I tried this:
DOCKER_PATH=$(which docker) docker-compose up
volumes:
- '/var/run/docker.sock:/var/run/docker.sock'
- ${DOCKER_PATH}:/usr/bin/docker:ro
But I get the error:
ERROR: Invalid bind mount spec "59f5e4fa06257c16a046ae7e5163401349f1c0bb394c881bcdf557a2f544811c:$(which:rw": Invalid volume destination path: '$(which' mount path must be absolute.
omnia source
share