Comments (12)
Ok I found my error... Using the Dockerfile directly does NOT mount the docker socket (DOOD) resulting in the container not having access to the docker server and the above crash.
from dagda.
To connect to my own mongoDB I updated the docker-compose from :
version: '2'
services:
dagda:
build: .
image: 3grander/dagda:0.8.0
container_name: dagda
networks:
- mdb
entrypoint: python dagda.py start -s 0.0.0.0 -p 5000 -m 192.168.99.100 -mp 27017
ports:
- "5000:5000"
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- /tmp:/tmp
depends_on:
- vulndb
vulndb:
image: mongo
container_name: vulndb
networks:
- mdb
ports:
- "27017:27017"
volumes:
- ./db:/data/db
networks:
mdb:
external: false
to
version: '2'
services:
dagda:
build: .
image: 3grander/dagda:0.8.0
container_name: dagda
networks:
- mdb
entrypoint: python dagda.py start -s 0.0.0.0 -p 5000 -m 192.168.99.100 -mp 27017
ports:
- "5000:5000"
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- /tmp:/tmp
networks:
mdb:
external: false
Now that the docker socket is mounted I don't have errors anymore :-)
BUT to interact with the container I must do the exports myself in the following manner :
docker exec -it 3e49abbfd862 /bin/sh -c "export DAGDA_HOST='192.168.99.100' && export DAGDA_PORT=5000 && python3 dagda.py docker images"
Am I using it wrong ? It feels weird to have to do the exports in the command line itself.
from dagda.
If you use docker-compose for running Dagda, the best option would be to use the REST API from your host.
Anyway, if you prefer running Dagda CLI within docker container, try to avoid "-c", I mean, run:
~$ docker exec -it 3e49abbfd862 /bin/sh
When you are in this point, only must export the variables once and you could run all Dagda commands without export these variables again.
from dagda.
I get what you mean.
Unfortunatly logging into the container is not the simplest thing to accomplish when scripting the scans, getting history etc...
I find it a bit disappointing that the CLI is kind of unreachable easily when using docker-compose :-)
Thanks for your help, I guess I'll use the REST API then.
from dagda.
Hi, when I run the dagda Image in docker-compose, it automatically exists. What should be the problem?
I cloned the project, build it as docker Image, then when I try to run it as docker-comose this happens,
from dagda.
@moisesdelacruz301997 Hi. Can you show your Dockerfile ?
from dagda.
Hi @Docteur-RS,
Sorry I forgot to attach this.
from dagda.
@moisesdelacruz301997 My bad, I meant the docker-compose file.
from dagda.
docker-compose.yml
from dagda.
Hi, the issue above is not happening anymore, I resolved the issue by re-cloning the project.
But now I'm having a new issue whenever I start the server.
This is the error that is displaying.
from dagda.
Hi @Docteur-RS ,
Re-cloning the project fixed my issue here.
Thanks a lot for your effort to investigate my issue.
from dagda.
@moisesdelacruz301997 Haha no problem.
If all problems on earth could be solved by re-cloning that would be wonderfull !
from dagda.
Related Issues (20)
- docker-compose instructions unclear and db error HOT 1
- docker-compose.yaml unfriendly to macos version of docker?
- dagda crashing when sent check job?
- When initialize database , I'm getting "TypeError: documents must be a non-empty list" error
- when i run python3 dagda.py vuln --product python --product_version=3.8-slim error 500 HOT 1
- When I inspect the container image, everything is fine. HOT 2
- Scanning image with included NPM project does not show NPM vulnerabilities HOT 1
- The problem of using docker-compose to build and deploy dagda is suspected to be a bug
- How to add custom falco rules HOT 1
- Vuln --init_status has been initializing and is never finishd
- docker image scan with dagda in standalone server mode. HOT 1
- Vuln --init fails HOT 2
- check result remains Analyzing HOT 1
- Dagda issue HOT 1
- Error while starting dagda (TypeError: an integer is required - got type bytes) HOT 3
- Scan containers running in K8s? HOT 1
- Many false-positives HOT 1
- Falcosecurity/ falco output file not found. HOT 4
- Publicly Accessible CVE Database
- docker compose build doesn't work: markupsafe dependency missing
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dagda.