http paste webserver in go
jabuxas
07ec53acd7
Some checks are pending
build abyss / build (amd64, linux) (push) Waiting to run
build abyss / build (arm64, linux) (push) Waiting to run
build abyss / build (ppc64le, linux) (push) Waiting to run
build abyss / build (riscv64, linux) (push) Waiting to run
Build Release / release linux/386 (release) Waiting to run
Build Release / release linux/amd64 (release) Waiting to run
Build Release / release darwin/amd64 (release) Waiting to run
Build Release / release windows/386 (release) Waiting to run
Build Release / release windows/amd64 (release) Waiting to run
|
||
---|---|---|
.github/workflows | ||
.gitignore | ||
abyss.go | ||
docker-compose.yml | ||
Dockerfile | ||
generate_config.sh | ||
go.mod | ||
go.sum | ||
handlers.go | ||
LICENSE | ||
README.md |
abyss
abyss is a basic single user http server made for uploading files (logs, images) and then sharing them to the internet
note: this is a project made for learning purposes, you should use other more mature projects if running in production. probably.
table of contents
running:
- run
./generate_config.sh
to setup the necessary environment variables
docker
- to run with docker, you can use docker compose:
docker compose up -d # might be docker-compose depending on distro
- dont change inside port of 8999 unless you know what you're doing
- when updating, run with
--build
instead:
docker compose up --build -d
manual
- to run it manually, build it with
go build -o abyss
and run:
./abyss
uploading
- then, simply upload your files with curl:
curl -F "file=@/path/to/file" -H "X-Auth: "$(cat /path/to/.key) http://localhost:8999/
docs
ABYSS_URL
: this is used for the correct formatting of the response ofcurl
.AUTH_USERNAME | AUTH_PASSWORD
: this is used to accesshttp://localhost:8999/tree
, which shows all uploaded filesUPLOAD_KEY
: this is key checked when uploading files. if the key doesn't match with server's one, then it refuses uploading.
todo:
- add upload of logs funcionality (like 0x0.st)
- add docker easy setup
add db for tracking of file names(dont need that)- add file browser (like file://)
- add file extension in its name
- login prompt when accessing /tree
- add rate limits