Spaces:
Sleeping
Sleeping
Update README.md
Browse files
README.md
CHANGED
@@ -1,45 +1,46 @@
|
|
1 |
-
---
|
2 |
-
title: File Sharing System
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
-
colorTo:
|
6 |
-
sdk: gradio
|
7 |
-
sdk_version: 4.31.5
|
8 |
-
app_file: app.py
|
9 |
-
pinned: false
|
10 |
-
license: apache-2.0
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
Gradio
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
- `
|
30 |
-
- `
|
31 |
-
- `
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
|
|
45 |
This project provides a simple yet effective solution for file storing and sharing. By leveraging Gradio for the front-end and MongoDB for the back-end, it ensures a seamless experience for users to upload and manage their files with easy access through generated URLs.
|
|
|
1 |
+
---
|
2 |
+
title: File Sharing System
|
3 |
+
emoji: 🔥
|
4 |
+
colorFrom: pink
|
5 |
+
colorTo: indigo
|
6 |
+
sdk: gradio
|
7 |
+
sdk_version: 4.31.5
|
8 |
+
app_file: app.py
|
9 |
+
pinned: false
|
10 |
+
license: apache-2.0
|
11 |
+
short_description: Share files and notes instantly.
|
12 |
+
---
|
13 |
+
|
14 |
+
# File Storing and Sharing System
|
15 |
+
|
16 |
+
This project is a file storing and sharing system built using Gradio for the front-end interface and MongoDB for the back-end database. The system allows users to upload files, which are then stored and managed within a specified directory. URLs for accessing these files are generated and stored in a MongoDB collection, making it easy to share and access the uploaded files.
|
17 |
+
|
18 |
+
## Key Components
|
19 |
+
|
20 |
+
### Gradio
|
21 |
+
Gradio is used to create the front-end interface, allowing users to interact with the file upload system through a simple and intuitive GUI.
|
22 |
+
|
23 |
+
### MongoDB
|
24 |
+
MongoDB is used to store metadata about the uploaded files, specifically the URLs where these files can be accessed. This project connects to a MongoDB instance using credentials stored in environment variables for security.
|
25 |
+
|
26 |
+
## Project Structure
|
27 |
+
|
28 |
+
### Environment Variables
|
29 |
+
- `SECRET_KEY`: Authetication Key to access data.
|
30 |
+
- `MONGO_USERNAME`: MongoDB username.
|
31 |
+
- `MONGO_PASSWORD`: MongoDB password.
|
32 |
+
- `REST_URI`: MongoDB URI for connecting to the database.
|
33 |
+
|
34 |
+
## How to Run
|
35 |
+
|
36 |
+
1. **Set Environment Variables**: Make sure to set the `SECRET_KEY`, `MONGO_USERNAME`, `MONGO_PASSWORD`, and `REST_URI` environment variables with your MongoDB credentials and URI.
|
37 |
+
2. **Install Dependencies**: Ensure you have `gradio`, `pymongo`, and other necessary packages installed.
|
38 |
+
3. **Run the Application**: Execute the script to start the Gradio interface and handle file uploads.
|
39 |
+
|
40 |
+
```bash
|
41 |
+
python your_script.py
|
42 |
+
```
|
43 |
+
|
44 |
+
## Conclusion
|
45 |
+
|
46 |
This project provides a simple yet effective solution for file storing and sharing. By leveraging Gradio for the front-end and MongoDB for the back-end, it ensures a seamless experience for users to upload and manage their files with easy access through generated URLs.
|