UPLOAD IMAGE PROJECT
This project enables users to upload images that are stored on Google Drive, and the URLs of the uploaded images displayed for the users so that they can directly view the images on the browser .
-
Clone the repository:
git clone https://github.com/janhavi-naik14/upload_image.git
-
Create a virtual environment and activate it:
python -m venv venv venv\Scripts\activate
-
Install Django:
pip install django
-
Navigate to the
imageuploader
directory:cd imageuploader
-
Install the required Google Drive libraries:
pip install google-auth google-auth-oauthlib google-auth-httplib2 google-api-python-client
-
Google Drive API activation:
- Go to the Google Cloud Console: https://console.cloud.google.com/
- Navigate to the IAM & Admin section and select Service accounts.
- Find the service account you’re using and click on the Actions (three dots) menu, then select Create key.
- Choose JSON as the key type and download the new key file.
- Put the JSON file in the
credentials.json
file in theimageuploader/imageuploader
directory.
- Run migrations to apply the changes:
python manage.py makemigrations python manage.py migrate
- Start the Django development server:
python manage.py runserver
The demo video of the whole webpage is in the project directory "demo_image_upload.mp4".