sefinek24 / sharex-express-server

Node.js project utilizing Express.js for hosting screenshots taken with ShareX.

Home Page:https://screenshots.sefinek.net

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸ“· Sharex Express.js Server

This project allows for the launching of a local server, intended for hosting screenshots taken with the Sharex program.

βœ”οΈ What does it include?

  • Configured CORS
  • Ready logger morgan
  • Ready middleware responsible for handling errors:
    • 429 Too Many Requests
    • 408 Request Timeout
    • 404 Not Found
    • 500 Internal Server Error
  • Static folder public
  • Blocking indexing of screenshots in the robots.txt file. Thanks to this, your screenshots will not be public.
  • Ready ecosystem.config.js file for PM2

πŸ€” What is this for?

With this solution, you don't have to upload screenshots to external services. Being an administrator, you can delete screenshots from the server with just a few clicks, thereby revoking everyone's access to the screenshot file.

☁️ Cloudflare Integration

  • For those utilizing Cloudflare, enhancing your security measures by incorporating specific expressions into the Web Application Firewall (WAF) comes highly recommended. This approach can significantly bolster your website's defense. Please visit this repository.

  • If you are using any proxy server (for example, Cloudflare), make sure to adjust the trust proxy setting in the index.js file. A value of 1 indicates a single proxy server. This adjustment is necessary for the server to accurately read the IP addresses of visitors.

πŸ“ How to use?

  1. Clone the repository:
    git clone https://github.com/sefinek24/sharex-express-server.git
  2. Install the necessary packages using npm install.
  3. Rename the .env.default file to .env and fill in the necessary data.
  4. Run the server using node ..
  5. Hosting:
    • At home (if you lack open ports or an external IP)
      See Cloudflare Tunnel Documentation. Remember, your domain must have Cloudflare DNS settings (at least that's what I believe).
  6. File server:
    • SAMBA
      See this tutorial.
  7. Configuration:
    • Windows
      windows.png
    • Sharex
      sharex-smb.png
      paths.png
  8. That's it! You can now take screenshots and upload them to your server.

πŸ’™ Thank you

If you find this repository useful, please consider giving it a star. If you need assistance or have any questions, feel free to open a new Issue.

πŸ“‘ License

This project is licensed under the MIT License.

About

Node.js project utilizing Express.js for hosting screenshots taken with ShareX.

https://screenshots.sefinek.net

License:MIT License


Languages

Language:JavaScript 100.0%