I have a Mongo
database on my server and I can connect to it using docker
.
I run the following command:
docker exec -it mongodb mongoexport --port 27017 -u "username" -p "password" --authenticationDatabase "admin" -d databaseName -c user --out /var/www/myTest/output.json
It seems that the command works without any problem and I get the message:
connected to: mongodb://localhost:27017/
exported 16 records
However, when I use FileZilla and look at the directory /var/www/myTest
, there is no file there. The folder is empty (I had created the folder myself earlier. If I use a new folder name, the folder is also not generated).
What have I done wrong? Is the file somewhere else?
Thanks in advance,
CodePudding user response:
That directory and the file is inside the mongoexport container