mirror of https://github.com/AlphaNecron/Void.git
discord-botdiscord-embeddockeremoji-urlfile-hostingfile-sharingfile-uploadhacktoberfestimageimage-hostinginvisible-urljavascriptmantinemantine-uinextjsreactreactjssharexsharex-servertypescript
818e35bc9e | ||
---|---|---|
.github/workflows | ||
.husky | ||
prisma | ||
public | ||
scripts | ||
server | ||
src | ||
twilight | ||
.eslintrc.js | ||
.gitignore | ||
LICENSE | ||
config.example.toml | ||
next-env.d.ts | ||
next.config.js | ||
package.json | ||
readme.md | ||
tsconfig.json | ||
void-env.d.ts | ||
yarn.lock |
readme.md
Requirements
node
>= 14- PostgreSQL
- Either
yarn
ornpm
Installation / Deployment
git clone https://github.com/AlphaNecron/Void.git
cd Void
yarn install # or npm install
cp config.example.toml config.toml
nano config.toml # edit the config file
yarn build # or npm run build
yarn start # or npm start
Reverse proxy (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
[core]
secure = false # Whether to use https or not
secret = 'supersecretpassphrase' # The secret used to sign cookie
host = '0.0.0.0' # The host Void should run on
port = 3000 # The port Void should run on
database_url = 'postgres://username:password@localhost:5432/db_name' # PostgreSQL database url
[bot]
enabled = false # Whether to enable the bot or not
prefix = '&' # Bot's prefix
token = '' # Bot's token
admin = [''] # Admin ids
log_channel = '' # The channel where logs are sent, leave blank to disable logging
hostname = 'example.com' # The hostname shortened urls should use in Twilight
[shortener]
allow_vanity = true # Whether to allow vanity urls or not
length = 6 # Slug length
route = '/go' # Route to serve shortened urls
[uploader]
raw_route = '/r' # Route to serve raw contents
length = 6 # Slug length
directory = './uploads' # The directory where images are stored
blacklisted = ['exe'] # Blacklisted extensions
Features
- Configurable
- Super fast
- Built with Next.js & React
- Token protected uploading
- Easy to setup
- Invisible URL
- Emoji URL
- Text previewing (with syntax highlighting)
- Video embed
- URL shortener
- Discord bot
Contribution
- All contribution must be made in
dev
branch, contributions inv0
will be closed.
Todo
- Docker support
- Discord integration
- Album / Bulk upload