SHARE
TWEET

Untitled

a guest May 22nd, 2019 68 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #Export from mongo:
  2. #Bash into docker :
  3. docker exec -it <container_id> /bin/bash
  4. #Export collection:
  5. mongoexport --db <db_name> -c <collection_name> --out <file_name>.json
  6. # back to local shell
  7. exit
  8. #CoPy file :
  9. docker cp <container-id>:/path/to/file ./local-dir
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top