Deprecated - This project will no longer get any updates.
A very.... very lightweight ShareX content uploader
Only a PoC, should not use in prod without reading below information
After 1 year of using this ShareX CDN, it can finally be deprecated. It still works and may still work in the future, however, there are some glaring issues that need to be solved before it can be deployed
- Speed - Being made in Python, it is honestly not really... "lightweight" | also the fact that it's made in Python simply makes it slower than if it was made in another programming language.
- R2 Dependence - The first version of this project I made included support for local storage.... and this does too, however it also requires R2 due to me having to migrate this over to Heroku (yeah, I am aware I'm broke)
- Security - This project has 0 security at all. I recently added an API key for some security, but it's a really hardcoded implementation. There is no frontend interface to generate keys, handle user authentication, etc. These are all things I wanted to do, but never found time.
- Pointless - I mean.... it's pointless... There are a lot of ShareX uploaders out there (even lightweight ones like this) that honestly probably run better, and have better security than this project.
I built this project for one reason: Easy to set up, and I was bored in class. (ok that was 2 reasons.... but.....)
- Download all files.
- Install dependencies.
python3 -m pip install -r requirements.txt
- If you want, you can get a S3 bucket instance from AWS or an R2 from cloudflare (its free!). If you don't want to, however, you can just delete that code.
- Make a random api key. It can honestly be anything thats a propper string. But tbh it's not really secure, so don't make it a password or anything. You can use a UUID or a SHA hash of some sort.
- The only thing you need to fill out in the code is the bucket URL, i never made that an env variable.
- Put your keys in a .env like such:
AWS_ACCESS_KEY_ID=""
AWS_SECRET_ACCESS_KEY=""
URL="http://127.0.0.1:5002/"
DD_KEY="" // this is your api key! put it here! (dont worry about the name of the variable)
- Run the python file with
python3 main.py
Your done! You can download your sharex custom uploader config file from<your URL>/config
Anyhow, I have no clue why I'm writing all of this for <100 lines of code that no one will even see (LOL)
primitt - ❤️ from The Homework Club