Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/swap76/move_assets_to_google_drive
Using this repo a beginner will be able move assets from databases or file systems onto Google Drive
https://github.com/swap76/move_assets_to_google_drive
file-upload google-drive mongodb multithreading python
Last synced: 12 days ago
JSON representation
Using this repo a beginner will be able move assets from databases or file systems onto Google Drive
- Host: GitHub
- URL: https://github.com/swap76/move_assets_to_google_drive
- Owner: Swap76
- License: agpl-3.0
- Created: 2019-11-29T05:44:41.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2019-11-29T18:53:44.000Z (about 5 years ago)
- Last Synced: 2024-11-19T13:37:45.342Z (2 months ago)
- Topics: file-upload, google-drive, mongodb, multithreading, python
- Language: Python
- Size: 26.4 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Move_Assets_To_Google_Drive
Using this repo a beginner will be able move assets from databases or file systems onto Google Drive## Getting started with the project
* Fork the repository on GitHub.
* Navigate to the folder of the repository.
* To run this project, you should have python3 and pip installed on your system.
If you don't have python3, MongoDB(If want to fetch records from DB) and pip, you can visit [The official site of python3](https://www.python.org/download/releases/3.0/)
to install them on your system.* Install python3 dependencies.
```
pip install -r requirement.txt
```* Enable Google Drive API for your account and obtain credentials for the same. Please follow the [Codelab](https://codelabs.developers.google.com/codelabs/gsuite-apis-intro/#9) for all this
* Now run following command for generating token for our python app to use Google Drive API.
```
python3 GoogleDriveSetup.py
```
This command will create a token.pickle file in the root directory* Setup MongoDB connection by providing Database URL, Database Name, Collection name in the respective program. Then in one terminal run
```
mongod
```
Keep this terminal running* Then Add a new key in the DB for Tracking Upload for this refer [Mongo Help](./mongo_setup.md). Run this commands in mongoshell
* Use following commands for running the programmes:-
For running a single thread program (Please make sure you create temp folder before running the program)
```
python3 singleThread_Upload.py
```
For running a multi thread program (Please make sure you create folders for downloading files)
```
python3 multiThread_Upload.py
```