immauss / openvas

Containers for running the Greenbone Vulnerability Manager. Run as a single container with all services or separate single applications containers via docker-compose.
GNU Affero General Public License v3.0
360 stars 102 forks source link

/var/run/gvmd.sock not present on the latest image #63

Closed dkade closed 3 years ago

dkade commented 3 years ago

I use the https://github.com/greenbone/gvm-tools && https://gvm-tools.readthedocs.io/en/latest/index.html .

My script creates targets, tasks, start them and in the end exports the report. So it's an automated process. It uses the sock to connect to GVM this is the default and recommended: https://gvm-tools.readthedocs.io/en/latest/connectiontypes.html#using-a-unix-domain-socket

Well with the lastest image gvmd.sock doesn't exist:

root@a32a5611b731:~# find / -name "gvmd.sock"
root@a32a5611b731:~#
immauss commented 3 years ago
looks like I typoed the tag when I pushed what I thought was good image yesterday. the 'latest' tag should be good now. please let me know if it's not.
cybermcm commented 3 years ago

I can see a socket but never used the scripts before, so "real" test has to be done by @dkade. @dkade: how do you interact with the scripts, they don't like to be called as root? My container runs as root, not best practice, I know, do you use another user/group?

dkade commented 3 years ago

@cybermcm you add the user to docker group and you don't need to run the container as root. I run nothing as root. https://docs.docker.com/engine/install/linux-postinstall/

My script is called by the same user that runs the container. To execute stuff inside the container I also don't user the root container user, but the openvas user: docker exec -i --user gvm openvas bash -c "<cmd>"

Checking now the latest image if everything is working.

dkade commented 3 years ago

Everything is working! :)