Coder Social home page Coder Social logo

droopy's Introduction

droopy

drop files here

droopy is a unique page where you simply drop and upload any file size, thanks to chunking. Based on Dropzone.js and php.

Default chunk size of 1000000b to bypass most enterprise proxies that would prevent more then 1Mb uploads.

Features

  • fallback methods and command line ready with curl
  • chunking: because sometimes ou are behind a dumb IDS or firewall that will prevent you from uploading more then 1MB at a time
  • simplicity
  • works out of the box. No configuration needed
  • forbidden characters protection in filenames uploaded
  • everything goes to /droopy/uploads

Installation

Clone the repo, mkdir droopy/uploads subfolder and other cutom subfolders if needed, serve it via nginx. Done.

Word of wisdom

There is no security at all, this is PHP. You need at least basic authentication at the nginx level, or bad things will happen to you.

nginx proxy sample

nginx proxy example below for linuxserver/nginx:

server {
  listen 80 dockerNetworkName;
  server_name dockerNetworkName;

  set $root /var/www/html/yoursite.com/public;
  if (!-d /var/www/html/yoursite.com/public) {
      set $root /config/www;
  }
  root $root;
  index index.html index.htm index.php;

  ## uploader
  location /droopy/uploads/ {
    autoindex on;
  }

  location / {
    # enable for basic auth
    #auth_basic "Restricted";
    #auth_basic_user_file /config/nginx/.htpasswd;

    try_files $uri $uri/ /index.html /index.php$is_args$args =404;
  }

  location ~ ^(.+\.php)(.*)$ {
      fastcgi_split_path_info ^(.+\.php)(.*)$;
      fastcgi_pass 127.0.0.1:9000;
      fastcgi_index index.php;
      include /etc/nginx/fastcgi_params;
  }

  # deny access to .htaccess/.htpasswd files
  location ~ /\.ht {
      deny all;
  }
}

TODO

  • mkdir subfolders
  • add some form options to the front such as chunk size, chunk on/off etc
  • loads cutomizations off a json file
  • show newly uploaded files directly under the dropzone
  • ability to delete newly uploaded files, until page refresh
  • create an nginx/php quirk to have dynamic and unique urls to share files
  • ability to setup retention from the front and default retention at the backend
  • protect filenames in the _GET
  • handle multiple custom subfolders based off a dictionary
  • add non-chunk, command line example
  • add non-chunk, native and basic 1-file upload form
  • handle filename without extension

droopy's People

Contributors

audioscavenger avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.