Describe the bug
Until recently, you could run docker build scoutsuite:latest in the root of the repository, then run docker run -t --rm scoutsuite:latests scout -h to execute scout suite and, with the right environment variables and volumes mounted get the results back on your local machine.
However, now, this is no longer possible.
To Reproduce
> docker run --rm -t rossja/ncc-scoutsuite scout
docker: Error response from daemon: OCI runtime create failed: container_linux.go:349: starting container process caused "exec: \"scout\": executable file not found in $PATH": unknown.
Additional context
My host OS is Mac OS
It would be really nice to return to a state where scout suite can be executed from the command line without having to have an interactive connection with scoutsuite.
Before, I was able to run scoutsuite as an automated CI task, but the recent docker changes have hosed my automation and I'm trying to figure out how to get back to a working state.
Looks like a duplicate of https://github.com/nccgroup/ScoutSuite/issues/882.
Should be fixed in https://github.com/nccgroup/ScoutSuite/pull/890, will be released next week. Appreciate if you can test.
This is still broken, I'm using docker compose from on master:
> docker run -it scoutsuite scout
docker: Error response from daemon: OCI runtime create failed: container_linux.go:349: starting container process caused "exec: \"scout\": executable file not found in $PATH": unknown.
@rossja could you please confirm?
This looks like a blend of:
docker runTo fix:
docker-compose up --build, ordocker build -t scoutsuite:latest .Further testing shows that running the scout command directly from outside of the container doesn't work. So, for example:
docker run -it scoutsuite:latest scout -h : fails
docker run -it scoutsuite:latest bash -c scout -h : fails
docker run -it scoutsuite:latest bash : followed immediately by scout -h in the running container: works
There's some nuance to docker there that I'm not fully grasping, where the python venv isn't getting set up when you run the first two commands. That can be worked around by running: docker run -it scoutsuite:latest /root/scoutsuite/bin/scout -h
Thanks @rossja, this is now merged into develop.
@j4v where was this resolved? Is there a commit or a PR link?
I can confirm on develop that docker run -it scoutsuite:latest /root/scoutsuite/bin/scout -h works. Is this path guaranteed to be fixed moving forward? docker run -it scoutsuite:latest scout -hstill does not work, so if I'm going to move forward with the absolute path, I'd hope the path won't change.
That path has not changed since the initial version was pushed to rossja/ncc-scoutsuite. I can't guarantee that it never will, but there are no plans to move it, and I see no reason it should change.