Coder Social home page Coder Social logo

alphanecron / void Goto Github PK

View Code? Open in Web Editor NEW
218.0 1.0 11.0 103 MB

Fast and elegant file hosting service.

License: MIT License

JavaScript 0.66% Shell 0.05% TypeScript 98.46% Dockerfile 0.83%
sharex sharex-server image image-hosting reactjs typescript javascript nextjs react file-upload

void's Introduction

Banner

A feature-rich self-hosted file hosting service.

Build v1 Docker v1 Stars Version Last commit

Warning This release is not fully stable and may subject to major changes in the future.
Neutron is not ready for usage due to uncompleted features.

Requirements

  • node >= 16
  • postgresql >= 14
  • yarn >= 3

Installation / Deployment

git clone https://github.com/AlphaNecron/Void.git --branch=v1
cd Void
yarn install # or npm install
cp config.example.json config.json
nano config.json # edit the config file
yarn prod # to build and start the production server
# or
yarn dev # to start the development server

Docker

git clone https://github.com/AlphaNecron/Void.git --branch=v1
cd Void
cp config.example.json config.json
nano config.json # edit the config file
docker pull alphanecron/void:v1
docker run -p 3000:3000 -v $PWD/config.json:/void/config.json -d alphanecron/void:v1

Docker compose

git clone https://github.com/AlphaNecron/Void.git --branch=v1
cd Void
cp config.example.json config.json
nano config.json # edit the config file
docker-compose up --build -d

Reverse proxy (with nginx)

server {
    listen              443 ssl;
    server_name         your.domain;
    ssl_certificate     /path/to/cert;
    ssl_certificate_key /path/to/key;
    ssl_protocols       TLSv1 TLSv1.1 TLSv1.2;
    ssl_ciphers         HIGH:!aNULL:!MD5;
    client_max_body_size 100M;
    location / {
        proxy_pass http://localhost:3000;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
}

Config schema

{
  "void": {
    "useHttps": false,
    // Whether to enable HTTPS for URLs created returned by API.
    "host": "0.0.0.0",
    // The host Void should run on.
    "port": 3000,
    // The port Void should run on.
    "secret": "secretmin32characters",
    // The secret key used to hash cookies. (*)
    "rateLimit": 1200,
    // Rate limit for users per hour. (**)
    "defaultDomain": "http://localhost:3000",
    // The base domain used for multiple purposes.
    "databaseUrl": "postgres://postgres:postgres@postgres/postgres",
    // The Postgres database URL.
    "url": {
      "allowVanityUrl": true,
      // Whether to allow users to shorten with vanity URLs.
      "length": 6
      // The maximum length for URLs generated with shortener and uploader.
    },
    "discordProvider": {
      "clientId": "YOUR DISCORD CLIENT ID",
      // Discord client id, you can grab one in the Application dashboard.
      "clientSecret": "YOUR DISCORD CLIENT SECRET"
      // Discord client secret, you can grab one in the Application dashboard as well.
    },
    "upload": {
      "outputDirectory": "./uploads",
      // The directory to save uploaded files.
      "blacklistedExtensions": [
        ".zip",
        ".exe"
      ]
      // Prevent users from uploading files with certain extensions. (**)
    }
  },
  "neutron": {
    "enabled": false,
    // Whether to enable the Discord bot
    "token": "YOUR_DISCORD_BOT_TOKEN",
    // Your Discord bot token
    "clientId": "YOUR_DISCORD_APP_CLIENT_ID"
    // Your Discord bot client id
  }
}

(*): If it is empty, a random key will be generated, otherwise, it must be at least 32 characters.
(**) Users with ADMINISTRATION permission or higher will not be affected by this.

Features

  • Configurable
  • Fast with eye-catching UI
  • Easy to install
  • Embed customization
  • Custom file viewer for texts, videos, images and audio files
  • Multiple URL charsets (alphanumeric, emoji and invisible)
  • Comes with prebuilt Docker images
  • Discord integration (Login with Discord)
  • Open registration with referral codes
  • Web upload with progress
  • Dedicated Discord bot, mobile application as well as desktop application (WIP).
    and more...

Techstack

Credits

  • v0 codebase from diced/zipline
  • Logo and favicon from icons8

Contributors

Contributors

Default credentials

  • Username: void
  • Password: voiduser

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.